How To: Eaccelerator!

-bash-3.00# yum check-update
Setting up repositories
update 100% |=========================| 951 B 00:00
base 100% |=========================| 1.1 kB 00:00
addons 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
Excluding Packages in global exclude list
Finished

gd.i386 2.0.28-4.4E.1 update
kernel.i686 2.6.9-22.0.2.EL update
krb5-devel.i386 1.3.4-17 base
krb5-libs.i386 1.3.4-17 base
openldap.i386 2.2.13-4 update
openssl.i686 0.9.7a-43.4 update
openssl-devel.i586 0.9.7a-43.4 update
pam.i386 0.77-66.13 update
shadow-utils.i386 2:4.0.3-58.RHEL4 update
udev.i386 039-10.10.EL4.3 update
wget.i386 1.10.2-0.40E update
-bash-3.00#






-bash-3.00# yum update autoconf
Setting up Update Process
Setting up repositories
update 100% |=========================| 951 B 00:00
base 100% |=========================| 1.1 kB 00:00
addons 100% |=========================| 951 B 00:00
extras 100% |=========================| 1.1 kB 00:00
Reading repository metadata in from local files
primary.xml.gz 100% |=========================| 51 kB 00:00
update : ################################################## 124/124
Added 3 new packages, deleted 0 old in 0.39 seconds
primary.xml.gz 100% |=========================| 29 kB 00:00
extras : ################################################## 124/124
Added 9 new packages, deleted 0 old in 0.33 seconds
Excluding Packages in global exclude list
Finished
Could not find update match for autoconf
No Packages marked for Update/Obsoletion
-bash-3.00#
 
Ok, now how do I disable the zend optimizer and only keep the loader.

Btw, thanks for all the help, you guys rule :D
 
Last edited:
; Directory in which the loadable extensions (modules) reside.
extension_dir = "/usr/local/lib/php/extensions/eaccelerator/"

That file does not exist this one however does ==>

/usr/local/lib/php/extensions/no-debug-non-zts-20020429/
and in there there's the eaccelerator.so
Thus means that the line below is also not correct.
;zend_extension="/usr/local/lib/php4/eaccelerator.so"

//yeah, lot of problems but hey, I'm learning :)
 
I've enterd this now ==>

; Directory in which the loadable extensions (modules) reside.
extension_dir = "/usr/local/lib/php/extensions/no-debug-non-zts-20020429/"
and
;zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20020429/eaccelerator.so"

If that is correct, then I don't know why my tmp/eaccelerator folder is still empty.

This is also correct. Can't figure out why.
;eaccelerator.cache_dir="/tmp/eaccelerator"

Do note I also have Zend installed.

Also if I upload eaccelerator.php it tells mee ==>

eAccelerator is not installed
 
Try uncommenting these lines:
Code:
;zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20020429/eaccelerator.so"
;eaccelerator.cache_dir="/tmp/eaccelerator"
The semi-colon in the beginning means they are comments, remove those.
 
work fine with CentOS 4.2 100% TESTED
Code:
cd /

mkdir Eaccelerator

cd Eaccelerator

wget [url]http://jaist.dl.sourceforge.net/sourceforge/eaccelerator/eaccelerator-0.9.4-rc1.tar.bz2[/url]

tar -xvjf eaccelerator-0.9.4-rc1.tar.bz2

cd eaccelerator-0.9.4-rc1

# Installation Steps
export PHP_PREFIX="/usr/local"

$PHP_PREFIX/bin/phpize
(Note that you need phpize, automake, autoconf and libtools installed)

work fine
./configure --enable-eaccelerator=shared --with-php-config=$PHP_PREFIX/bin/php-config

make

make install

cd /tmp

mkdir eaccelerator

chmod 0777 eaccelerator

cp /usr/local/lib/php.ini /usr/local/lib/php.ini.backup

pico -w /usr/local/lib/php.ini

Search for
;Directory in which the loadable extensions (modules) reside.

extension_dir = "/usr/local/lib/php/extensions/eaccelerator/"

# and change the dir according to what you get after make install, or you can use locate eaccelerator.so to check the directory

Search for ;Windows Extensions, if you don't know how, press Ctrl+W and add...

zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20020429/eaccelerator.so"
eaccelerator.shm_size="32"
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="0"
eaccelerator.shm_prune_period="0"
eaccelerator.shm_only="0"
eaccelerator.compress="1"
eaccelerator.compress_level="9"

Save and Exit

service httpd restart

Wael
 
Any guide to install it on FreeBSD? :)

Thx!

Nevermind! just installed it :)
 
Last edited:
weird! Memory Allocated, Cached Scripts are reset every midnight.

Check my crontab, I only see newsyslog running at that time.

0 * * * * root newsyslog
 
more of my crontab settings.

2 0-23/6 * * * root echo 'action=vacation&value=all' >> /usr/local/directadmin/data/task.queue;
5 0 * * * root /usr/sbin/quotaoff -a; /sbin/quotacheck -aug; /usr/sbin/quotaon -a;
3 3 * * * root echo 'action=tally&value=all' >> /usr/local/directadmin/data/task.queue
40 1 1 * * root echo 'action=reset&value=all' >> /usr/local/directadmin/data/task.queue
0 4 * * * root echo 'action=check&value=license' >> /usr/local/directadmin/data/task.queue
 
when apache restarts for log rotation and domain changes all cached scripts in memory will be reset.
 
Back
Top