Rapid installation of php-memcached extensions via PECL
Previously installed php-memcached is always through the source code compile way, that dependency, compile speed let you wait ah, not annoying ah. Inadvertently learned from the Internet can use PECL to quickly install the extension, here to organize and record it.
System Environment: CentOS-7.1
1, installation libmemcached
# yum-y Install libmemcached-devel Loaded plugins:langpacksresolving dependencies--> Running Transaction Check--- ; Package libmemcached-devel.x86_64 0:1.0.16-3.el7 'll be installed--> processing dependency:cyrus-sasl-devel ( x86-64) for package:libmemcached-devel-1.0.16-3.el7.x86_64--> Running transaction Check---> Package Cyrus-sasl-devel.x86_64 0:2.1.26-17.EL7 would be installed--> processing DEPENDENCY:CYRUS-SASL (x86-64) = 2.1.26-17. EL7 for package:cyrus-sasl-devel-2.1.26-17.el7.x86_64--> Running transaction Check---> Package cyrus-sasl.x86_ 0:2.1.26-17.el7 'll be installed ....... Omit a number of lines ..... Installed: libmemcached-devel.x86_64 0:1.0.16-3.el7 Dependency installed: cyrus-sasl.x86_64 0:2.1.26-17.el7 cyrus-sasl-devel.x86_64 0:2.1.26-17.el7 complete!
2. Install php-memcached Extension
3. Append module to php.ini file
# extension=memcached.so
Tips: If you use pecl install memcached to install successfully, you can use the following methods-
# pecl Download memcached# tar zxvf memcached-xxx# cd memcached-xxx# phpize#./configure--with-libmemcached-dir=/xxxx/xx X/xxx