After you install and configure your environment properly under CentOS LAMP 6 you want to install APC.
What you need before starting:
– PEAR
– Development of interfaces PHP, Apache & PCRE
– A C & Make tool.

If your server doesn’t have these libraries already installed use the following command to do so.

# yum install php-pear php-devel httpd-devel pcre-devel gcc make

Last, run the compilation of the APC extension.

# pecl install apc

The following questions will be asked, personally I used the defaults.

Enable internal debugging in APC [no]:
Enable per request file info about files Used From The APC cache [no]:
Enable spin locks (EXPERIMENTAL) [no]:
Enable memory protection (EXPERIMENTAL) [no]:
Enable pthread mutexes (default) [yes]:
Enable pthread read / write locks (EXPERIMENTAL) [no]:

To enable the PHP extension you should edit the php.ini configuration file and add this to the end of the file:

extension = apc.so

Restart Apache

# /etc/ini.d/httpd restart

You can check you have successfully installed APC via phpinfo().

Go to your HTTP directory

# cd /var/www/html/

Create and edit the file

# nano info.php

Paste the following lines:

<?php
phpinfo();
?>

Hit Control+X, nano will ask if you want to save the changes hit Y and hit Enter

Browse to your HTTP directory and run the file http://localhost/info.php

Also, do not hesitate to use the PHP APC administration. Here, we copy in your HTTP directory.

# cp /usr/local/lib/php/apc.php /var/www/html/apc.php

You can access this file using your browser at http://localhost/apc.php

Tagged with:
 

Leave a Reply

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

Cheap Oakley Sunglasses Fifa Coins Fifa Coins Cheap Fifa Coins buy cheap fifa coins buy fifa coins cheap fifa coins fifa coins sale Fifa Coins cheap fifa coins sale fifa coins for sale cheap fifa coins price