Posts Tagged ‘eAccelerator’

Linux Kloxo-mr下安装eaccelerator1.0和Xcache-3.1.0

星期三, 二月 26th, 2014

eaccelerator1.0

[root@vps ~]#wget wget https://codeload.github.com/eaccelerator/eaccelerator/legacy.tar.gz/master
[root@vps ~]#tar -zxvf eaccelerator-eaccelerator-42067ac.tar.gz
[root@vps ~]#cd eaccelerator-eaccelerator-42067ac
[root@vps eaccelerator-eaccelerator-42067ac]#phpize
[root@vps eaccelerator-eaccelerator-42067ac]#./configure --enable-eaccelerator=shared --with-php-config=/usr/bin/php-config
[root@vps eaccelerator-eaccelerator-42067ac]#make && make install
[root@vps ~]#cd ..
[root@vps ~]#find / -name eaccelerator.so
/usr/lib/php/modules/eaccelerator.so
[root@vps ~]#mkdir /tmp/eaccelerator
[root@vps ~]#chmod 0777 /tmp/eaccelerator
[root@vps ~]#vi /etc/php.d/eaccelerator.ini

输入以下内容

[eaccelerator]
extension="/usr/lib/php/modules/eaccelerator.so"
eaccelerator.shm_size="64"
eaccelerator.cache_dir="/tmp/eaccelerator"
eaccelerator.enable="1"
eaccelerator.optimizer="1"
eaccelerator.check_mtime="1"
eaccelerator.debug="0"
eaccelerator.log_file = "/var/log/eaccelerator_log"
eaccelerator.filter=""
eaccelerator.shm_max="0"
eaccelerator.shm_ttl="0"
eaccelerator.shm_prune_period="0"
eaccelerator.shm_only="0"
eaccelerator.compress="1"
eaccelerator.compress_level="9"
eaccelerator.keys = "shm_and_disk"
eaccelerator.sessions = "shm_and_disk"
eaccelerator.content = "shm_and_disk"
[root@vps ~]#service httpd restart
[root@vps ~]# php -v
PHP 5.4.24 (cli) (built: Jan 10 2014 18:37:23)
Copyright (c) 1997-2013 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2013 Zend Technologies
with eAccelerator v1.0-dev, Copyright (c) 2004-2012 eAccelerator, by eAccelerator

Xcache-3.1.0

#wget http://xcache.lighttpd.net/pub/Releases/3.1.0/xcache-3.1.0.tar.gz
#tar -zxvf xcache-3.1.0.tar.gz
#cd xcache-3.1.0
#phpize
#./configure -with-php-config=/usr/bin/php-config -enable-xcache -enable-xcache-coverager -enable-inline-optimization -disable-debug
#make && make install
#vi /etc/php.d/xcache.ini

增加或修改以下内容

[xcache-common]
zend_extension = /usr/lib/php/modules/xcache.so
[xcache.admin]
xcache.admin.enable_auth = On
xcache.admin.user = "admin"
xcache.admin.pass = md5($pass)
#cp -ar htdocs /www/root/
#service php-fpm restart
#service httpd restart
#php -v
PHP 5.4.24 (cli) (built: Jan 10 2014 18:37:23) 
Copyright (c) 1997-2013 The PHP Group
Zend Engine v2.4.0, Copyright (c) 1998-2013 Zend Technologies
    with XCache v3.1.0, Copyright (c) 2005-2013, by mOo
    with XCache Cacher v3.1.0, Copyright (c) 2005-2013, by mOo
    with XCache Coverager v3.1.0, Copyright (c) 2005-2013, by mOo

eaccelerator1.0导致wordpress添加媒体和可视化无反应故障

星期二, 二月 25th, 2014

本来我的两个wordpress博客是可以正常使用的,但是今天不知道为什么突然出现了“添加媒体”和“可视化”没有反应的故障了.我以为是wordpress博客的源码问题,所以参照了网上的一些方法来进行修复,但是问题却没有得到解决.
按照网上的方法是:
1:编辑 wp-config.php 在文件末端加上以下代码.

define('CONCATENATE_SCRIPTS', false );

2:编辑 post-new.php

include( ABSPATH . 'wp-admin/admin-footer.php' );

在上边这一行上边加上以下代码.

echo'<script type="text/javascript" src="/wp-includes/js/jquery/jquery.js"></script>';

但是经过我测试,这两种方法都没有解决我的问题,于是我想起昨天我安装了eaccelerator1.0,不知道是不是这个原因.于是我登录VPS服务器,将eaccelerator1.0卸载以后,问题解决了.

Kloxo环境下安装eAccelerator

星期日, 八月 12th, 2012

转载自:http://blog.vpswind.com/archive/104.html
eaccelerator-0.9.5.3:http://autosetup1.googlecode.com/files/eaccelerator-0.9.5.3.tar.bz2
eaccelerator-0.9.6.1:http://acelnmp.googlecode.com/files/eaccelerator-0.9.6.1.tar.bz2
在putty中执行以下命令,安装完成后,如果你是apache的就执行service httpd restart命令,如果你是使用lighttpd的,就执行service lighttpd restart命令,重启后可以在putty中执行 php -v 命令来查看.

yum install -y make
wget http://autosetup1.googlecode.com/files/eaccelerator-0.9.5.3.tar.bz2
bzip2 -d   eaccelerator-0.9.5.3.tar.bz2
tar -xvf eaccelerator-0.9.5.3.tar
cd eaccelerator-0.9.5.3
phpize
./configure --enable-eaccelerator=shared --with-php-config=/usr/bin/php-config --with-eaccelerator-shared-memory
make
make install

cat >/etc/php.d/eaccelerator.ini< <EOF
extension="eaccelerator.so"
eaccelerator.shm_size="64"
eaccelerator.cache_dir="/tmp/eaccelerator"
eaccelerator.enable="1"
eaccelerator.optimizer="1"
eaccelerator.check_mtime="1"
eaccelerator.debug="0"
eaccelerator.log_file = "/var/log/eaccelerator_log"
eaccelerator.filter=""
eaccelerator.shm_max="0"
eaccelerator.shm_ttl="0"
eaccelerator.shm_prune_period="0"
eaccelerator.shm_only="0"
eaccelerator.compress="1"
eaccelerator.compress_level="9"
eaccelerator.keys = "shm_and_disk"
eaccelerator.sessions = "shm_and_disk"
eaccelerator.content = "shm_and_disk"
EOF
service httpd restart
service lighttpd restart