服务器php启动
Posted 鹰搏长空08
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了服务器php启动相关的知识,希望对你有一定的参考价值。
php.ini放在--with-config-file-path设置路径下lib文件夹中才找的到!!!! fpm的配置文件需要放在这个位置/usr/local/etc/php-fpm.conf,暂时不知道咋改; http://blog.csdn.net/xiaog351/article/details/47421969 php: { cd /opt/apps wget http://cn2.php.net/distributions/php-5.6.26.tar.gz tar -xzvf php-5.6.26.tar.gz cd php-5.6.26/ ;./configure --prefix=/opt/apps/php(安装目录) --with-config-file-path=/opt/apps/php(配置目录) --enable-fpm --with-mysql(php-fpm) yum install libxml2* -y make make test make install vim /etc/profile 添加: PHP_HOME=/opt/apps/php export PATH=$PATH:$PHP_HOME/bin source /etc/profile php -v 查看 } php.ini放在--with-config-file-path设置路径下lib文件夹中才找的到!!!! ssl { cd /opt/apps/php-5.6.26/ext/openssl cp config0.m4 config.m4 /opt/apps/php/bin/phpize ./configure --with-openssl --with-php-config=/opt/apps/php/bin/php-config make make test make install 在php.ini内加入以下内容: extension_dir = "/opt/apps/php/lib/php/extensions/no-debug-non-zts-20131226" extension = "openssl.so" 重启php、nginx后生效 } php/sbin/php-fpm -y /opt/apps/php/etc/php-fpm.conf -c /opt/apps/php/php.ini 装memcached扩展 { #wget http://pecl.php.net/get/memcache-2.2.6.tgz # tar zxf memcache-2.2.6.tgz # cd memcache-2.2.6 # /usr/local/php/bin/phpize # ./configure --with-php-config=/usr/local/php/bin/php-config --enable-memcache # make # make install } 装pdo_mysql扩展 { # cd /opt/php/php-5.6.30/ext/pdo_mysql # /usr/local/bin/phpize # ./configure --with-pdo-mysql=/opt/apps/mysql --with-php-conifg=/usr/local/bin/php-confi # make # make install }
以上是关于服务器php启动的主要内容,如果未能解决你的问题,请参考以下文章