centos-php-memcached Extension Note that the PHP installation is
Memcached extension, with PHP's
Memcahe extension is a little different. php_memcached supports binary protocol protocol, and Php_memcache protocol does not support, php_memcached support multi-process concurrency processing problem for the same key, Memcached also has a very commendable place, that is, flag is not in the operation of the time set, but with a unified setoption (). The memcached implements more memcached protocols. Here's a php_memcache VS php_memcached
Https://code.google.com/p/memcached/wiki/PHPClientComparison
php-memcached: http://pecl.php.net/package/memcached Installation Steps 1, because php_memcached is dependent on libmemcached library, so first install libmemcached library, need to install libmemcached-1.x above version.
1 2 |
#yum Info libmemcached #yum Install libmemcached-y |
2, install the extension, here we use PHP comes with the pecl command to install the PHP extension.
PHP Official Introduction pecl:pecl (PHP Extension Community library), PHP extension libraries, it provides a series of known extensions, written in other languages such as C + +, most of them in the form of DLLs (dynamic link library) to reflect, is faster than pear, but unlike pear, pecl needs to be configured on the server and registered with the host. Pecl.php/.net pecl download can be directly extracted to Php/ext directory, Pecl is through? PEAR packaging System to the PHP extension library repository.
1 2 |
#/usr/local/php/bin/pecl Info memcached #/usr/local/php/bin/pecl Install memcached |
3, after the installation is complete in the configuration file add
1 |
#vim/usr/local/php/etc/php.ini |
extension=memcached.so
4. Restart the Web server
5. Verification
1 |
#/usr/local/php/bin/php-m |grep Memcache |
memcache
memcached
Centos-php_memcached Extended Installation