we assume apache2,mysql5, and php5 were installed on machine.
if not yet, we can follow this step
Downloading package, ekstract, and compile
#cd /root
#wget http://bart.eaccelerator.net/source/0.9.6/eaccelerator-0.9.6.tar.bz2
#tar –jxvf eaccelerator-0.9.6.tar.bz2
#cd eaccelerator-0.9.6
#export PHP_PREFIX="/usr/local"
#$PHP_PREFIX/bin/phpize
#./configure --enable-eaccelerator=shared --with-php-config=$PHP_PREFIX/bin/php-config
#make
#make install
Configure php.ini to support eaccelerator
#vi /usr/local/lib/php.ini
### add few lines below in the end of php.ini ###
[eaccelerator]
zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20090626/eaccelerator.so"
eaccelerator.shm_size="128"
eaccelerator.cache_dir="/tmp"
eaccelerator.enable="1"
eaccelerator.optimizer="1"
eaccelerator.check_mtime="1"
eaccelerator.debug="0"
eaccelerator.filter=""
eaccelerator.shm_max="0"
eaccelerator.shm_ttl="300"
eaccelerator.shm_prune_period="120"
eaccelerator.shm_only="0"
eaccelerator.compress="1"
eaccelerator.compress_level="9"
Create eaccelerator tmp dir
#mkdir /tmp/eaccelerator
#chmod 0777 /tmp/eaccelerator
NOTE : zend optimizer 3.3.3 is not support with PHP 5.3.0
Modify kernel.shmmax value
#vi /etc/sysctl.conf
### add line below ###
kernel.shmmax = 134217728
Refresh the value with sysctl
#/sbin/sysctl -p
if get problem
vmsuse:~/eaccelerator-0.9.6 # /sbin/sysctl -p
net.ipv4.icmp_echo_ignore_broadcasts = 1
net.ipv4.conf.all.rp_filter = 1
fs.inotify.max_user_watches = 65536
net.ipv4.conf.default.promote_secondaries = 1
net.ipv4.conf.all.promote_secondaries = 1
kernel.shmmax = 134217728
How to fix?
Who error close with #
Refresh the value with sysctl
#/sbin/sysctl –p
Restart Apache Webserver
#/usr/local/apache2/bin/apachectl stop
#/usr/local/apache2/bin/apachectl start
cek!
vmsuse:~ # php -v
PHP 5.3.1 (cli) (built: Apr 15 2010 08:50:59)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies
with eAccelerator v0.9.6, Copyright (c) 2004-2010 eAccelerator, by eAccelerator
0 comments:
Post a Comment