1. Installation
# Tar XF xcache-3.2.0.tar.bz2
# CD xcache-3.2.0
#/usr/local/php/bin/phpize
#./configure--enable-xcache--with-php-config=/usr/local/php/bin/php-config
# Make && make install
At the end of installation. such as the following line will appear:
Installing Shared extensions:/usr/local/php/lib/php/extensions/no-debug-zts-20100525/
2, edit php.ini, integrate PHP and XCache:
First, the example configuration provided by XCache to import php.ini, the Xcache.ini file is added at the end of the php.ini file;
One thing to note here is how VI copies and pastes in two files:
Edit two files at the same time, copy the clip text in two files vi file1 file2 NYY Open two files at the same time, copy the line where the cursor at file 1 is located: N Switch to File 2 (n=next) p Paste the copied line at the cursor of file 2: N switches back to file 1
Description: The Xcache.ini file is in the XCache Source code folder.
Next edit/opt/php/lib/php.ini,
Locate the line that starts with extension, and change to such as the following line:
# Vim/opt/php/lib/php.ini
Extension =/usr/local/php/lib/php/extensions/no-debug-non-zts-20100525/xcache.so
# Service PHP-FPM Restart
Open phpinfo.php to check the execution environment of PHP:
XCache Accelerating PHP