Linux PHP Add extension library

Source: Internet
Author: User
Tags zts

centos_7.2 compiling and installing php_5.6.20 adding extension modules

To add a zendguardloader extension:

# unzip zendguardloader.so into "/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/" directory

chmod A+x/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/zendguardloader.sovim/etc/php.ini


# add [zendguardloader]extension = "/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/zendguardloader.so" zend_loader.enable = 1zend_loader.disable_licensing = 0zend_loader.obfuscation_level_support = 3


Service PHP-FPM Restart

To add a redis extension:


Tar zxvf phpredis-2.2.7.tgzrm-rvf package.xmlmv redis-2.2.7//usr/local/php/include/php/ext/redis/cd/usr/local/php/ Include/php/ext/redis//usr/local/php/bin/phpize./configure--with-php-config=/usr/local/php/bin/ Php-configmakemake Install


Vim/etc/php.ini
=
Service PHP-FPM Restart

To add a memcache extension:


Tar zxvf phpmemcache-3.0.8.tgzrm-rvf package.xmlmv memcache-3.0.8//usr/local/php/include/php/ext/memcache/cd/usr/ Local/php/include/php/ext/memcache//usr/local/php/bin/phpize./configure--with-php-config=/usr/local/php/bin/ Php-configmakemake Install


Vim/etc/php.ini
=
Service PHP-FPM Restart

To add a memcached extension:


Tar zxvf phpmemcached-2.2.0.tgzrm-rvf package.xmlmv memcached-2.2.0//USR/LOCAL/PHP/INCLUDE/PHP/EXT/MEMCACHED/CD/ Usr/local/php/include/php/ext/memcached//usr/local/php/bin/phpize./configure--with-php-config=/usr/local/php/ Bin/php-config--with-libmemcached-dir=/usr/local/libmemcached/--enable-memcachedmakemake Install


Vim/etc/php.ini
# add [memcached]extension = "/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/memcached.so"
Service PHP-FPM Restart

To add a imagick extension:


Tar zxvf phpimagick-3.4.0.tgzrm-rvf package.xmlmv imagick-3.4.0//usr/local/php/include/php/ext/imagick/cd/usr/ Local/php/include/php/ext/imagick//usr/local/php/bin/phpize./configure--with-php-config=/usr/local/php/bin/ Php-config--with-imagick=/usr/local/imagemagickmakemake Install


Vim/etc/php.ini
# add [imagick]extension = "/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/imagick.so"
Service PHP-FPM Restart

To add a xcache extension:


Tar zxvf phpxcache-3.2.0.tar.gzmv xcache-3.2.0//usr/local/php/include/php/ext/xcachecd/usr/local/php/include/php/ Ext/xcache/usr/local/php/bin/phpize./configure--with-php-config=/usr/local/php/bin/php-config--enable-xcache-- Enable-xcache-coverager--enable-xcache-optimizermakemake Install



Mkdir-p/home/xcachetouch/home/xcache/xcachechmod 777/home/xcache/xcacheecho-n "xcache-Passw0rd!" | Md5sumcp-r/usr/local/php/include/php/ext/xcache/htdocs//home/www/html/xcachechown www:www-r/home/www/html/ xcache/


Vim/etc/php.ini


#  add [xcache]extension =  "/usr/local/php/lib/php/extensions/no-debug-non-zts-20131226/xcache.so" xcache.shm_scheme =  "Mmap" xcache.size = 26mxcache.count = 5 xcache.slots  = 8Kxcache.ttl = 3600xcache.gc_interval = 300xcache.var_size =  4mxcache.var_count = 5 xcache.var_slots = 8kxcache.var_ttl = 0xcache.var_ Maxttl = 0xcache.var_gc_interval = 300xcache.test = offxcache.readonly_ protection = offxcache.mmap_path =  "/home/xcache/xcache" xcache.coredump_directory =   "Xcache.cacher = onxcache.stat = onxcache.optimizer = off[xcache.admin" xcache.admin.enable_auth = onxcache.admin.user =  "admin" xcache.admin.pass =  " 42ddb5e3f0dc3c4807a2b0c62b8d4d87 "[Xcache.coverager]xcache.coverager = offxcache.coverager_autostart  = onxcache.coveragedump_directory =  "" 



This article is from the "Dream to Reality" blog, please be sure to keep this source http://lookingdream.blog.51cto.com/5177800/1861611

Linux PHP Add extension library

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.