我通过使用repo从我的centos 6.6安装了php 5.6,apache 2.2和php-fpm
https://webtatic.com/packages/php56/
我遵循这个指令abd尝试使php-fpm工作http://www.garron.me/en/linux/apache-mpm-worker-php-fpm-mysql-centos.html
但是这个教程有些不同之处:
fcgid.conf
# This is the Apache server configuration file for providing FastCGI support # through mod_fcgid # # Documentation is available at # http://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html LoadModule fcgid_module modules/mod_fcgid.so # Use FastCGI to process .fcg .fcgi & .fpl scripts AddHandler fcgid-script fcg fcgi fpl # Sane place to put sockets and shared memory file FcgidIPCDir /var/run/mod_fcgid FcgidProcessTableFile /var/run/mod_fcgid/fcgid_shm
<IfModule mod_fastcgi.c> ScriptAlias /fcgi-bin/ /usr/bin/ AddType application/x-httpd-php .php AddHandler php-fastcgi .php Action php-fastcgi /fcgi-bin/php-cgi FastCgiExternalServer /usr/bin/php-cgi -host 127.0.0.1:9000 </IfModule>
任何人都知道如何configuration? 在phpinfo中没有php-fpm信息显示,我使用echo php_sapi_name();它返回'cgi-fcgi'
我试图删除,有一个错误无效的命令'FastCgiExternalServer',也许拼错或定义
您正在使用fcgid模块,但不使用mod_fastcgi,没有FastCgiExternalServer指令。 但我不知道如何使fcgid和php-fpm在一起。
我终于用php-fpm使用nginx,而apache可以继续打开