formats

Make Your Web Server Snappy With php-apc

Published on August 3, 2011, by + in sysadmin.







In Debian / Ubuntu, simply installing one package will instantly make your web server faster. (That is, if you are serving up php!)




Here ya go:

sudo apt-get install php-apc





Next, edit the following file:

$ sudo nano /etc/php5/conf.d/apc.ini



And put in the following values. Increase the apc.shm_size as high as is available:

extension=apc.so
apc.shm_size=64M
apc.ttl=3600
apc.gc_ttl=3600
apc.mmap_file_mask=/tmp/apc.XXXXXX



php-apc is a php extension known as a ‘PHP accelerator‘ which improves performance by directly executing code that is cached into ram. WordPress plugins such as w3-total-cache can make use of apc.

scottlinux.com has php-apc installed with 256M of available apc memory!

Sweet!

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Notify me of followup comments via e-mail. You can also subscribe without commenting.

Home sysadmin Make Your Web Server Snappy With php-apc