Installing eaccelerator on freebsd

Installing eaccelerator On FreeBSD 6.2

I have installed using ports

cd /usr/ports/www/eaccelerator
make
make install

It will install the eaccelerator and now we are ready make changes in config files

First create a cache directory and manage its permissions

mkdir /tmp/eaccelerator
chown www /tmp/eaccelerator
chmod 0700 /tmp/eaccelerator

\r\n


Then I have update my extensions.ini from default location which is at

/usr/local/etc/php/

Insert following lines

;Following line will enable the eaccelerator support

extension=eaccelerator.so

;Following lines will configure eaccelerator

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"

Now restarts apache by following command

apachectl graceful

and check the eaccelerator is configured properly by giving a command

php -i | grep eaccelerator

OR

php -i | grep eAccelerator

Further Reading

http://eaccelerator.net/
http://en.wikipedia.org/wiki/EAccelerator

Categories