Install APC on Ubuntu for PHP

  • Avinash
  • 0
  • Aug 11, 2012
  • Tutorial

In one of earlier article we have seen about installing MemcacheD on Ubuntu. Now in this article we will see how to install APC on Ubuntu for PHP.

What is APC?

APC Stands for Alternative PHP Cache. Let’s take definition from the php.net

The Alternative PHP Cache (APC) is a free and open opcode cache for PHP. Its goal is to provide a free, open, and robust framework for caching and optimizing PHP intermediate code.

We won’t talk much about APC on this article. In this article we will see how to install APC on Ubuntu for PHP.

This process include only two steps. You will need root access to perform these steps.

Install APC

You need to run below command on your terminal.

sudo apt-get install php-apc
sudo apt-get install php-apc

See below image for more information.

Install APC on Ubuntu for PHP

Restart Apache

Now after installing the APC all you need to do is restart the apache or php service to take the apc in effect.

Restart Apache

sudo service apache2 restart
sudo service apache2 restart

Restart PHP

sudo service php-fpm restart
sudo service php-fpm restart

Now check your php configuration using phpinfo();. Please have a look at below image you will find similar kind of block in your configuration also. If so then you are done.

PHP APC Configuration

Comments are always open if you have any suggestion/comments for above process.

Related Posts

Written by Avinash

Avinash Zala is leading various projects which deals with the various technology involved with the web. A combination of perfect technical and management skills. Avinash would like to chat with you and convert your imagination into the working system. You can get in touch with him on Facebook and Twitter.

View all posts by: