需要autoconf支持
apt-get install autoconf
下面安装eAccelerator
cd /usr/local/src
mkdir eAccelerator
下载最新的eAccelerator 。
cd eAccelerator
wget eaccelerator-*.tar.bz2
tar -xvjf eaccelerator-*.tar.bz2
cd eaccelerator-*
安装步骤:
输出目录,安装目录
export PHP_PREFIX=”/usr/local”
$PHP_PREFIX/bin/phpize
//显示你需要的phpize 配置安装
./configure \
–enable-eaccelerator=shared \
–with-php-config=$PHP_PREFIX/bin/php-config
//编译
make
//安装
make install
#现在创建缓存的目录 或Cache directory
cd /tmp
mkdir eaccelerator
chmod 0777 eaccelerator
编辑 php.ini
在[Zend]上面加
[eaccelerator]
zend_extension=”/usr/local/lib/php/extensions/no-debug-non-zts-20060613/eaccelerator.so”
eaccelerator.shm_size=”1″
eaccelerator.cache_dir=”/tmp/eaccelerator”
eaccelerator.enable=”1″
eaccelerator.optimizer=”1″
eaccelerator.check_mtime=”1″
eaccelerator.debug=”0″
eaccelerator.filter=””
eaccelerator.shm_max=”0″
eaccelerator.shm_ttl=”3600″
eaccelerator.shm_prune_period=”3600″
eaccelerator.shm_only=”0″
eaccelerator.compress=”1″
eaccelerator.compress_level=”9″
eaccelerator.keys = “disk_only”
eaccelerator.sessions = “disk_only”
eaccelerator.content = “disk_only”
重启apache
发表回复