+ -
当前位置:首页 → 问答吧 → php-fpm平滑变更php.ini问题

php-fpm平滑变更php.ini问题

时间:2009-07-04

来源:互联网

最近 看张宴的 BLOG,装NGINX+MYSQL+PHP
NGINX和 MYSQL都 成功安装,但是 装PHP最后一步时遇到了 问题
创建php-fpm配置文件(php-fpm是为PHP打的一个FastCGI管理补丁,可以平滑变更php.ini配置而无需重启php-cgi):
    在/usr/local/php5/etc/目录中创建php-fpm.conf文件:
    rm -f /usr/local/php5/etc/php-fpm.conf
    vi /usr/local/php5/etc/php-fpm.conf

按照这个步凑走 ,把 配置内容[在 这里省略]输入,然后执行
ulimit -SHn 51200
/usr/local/php5/sbin/php-fpm start

结果显示 :
Starting php_fpm Error in argument 1, char 1: no argument for option -
Usage: php-cgi [-q] [-h] [-s] [-v] [-i] [-f <file>]
       php-cgi <file> [args...]
  -a               Run interactively
  -C               Do not chdir to the script's directory
  -c <path>|<file> Look for php.ini file in this directory
  -n               No php.ini file will be used
  -d foo[=bar]     Define INI entry foo with value 'bar'
  -e               Generate extended information for debugger/profiler
  -f <file>        Parse <file>.  Implies `-q'
  -h               This help
  -i               PHP information
  -l               Syntax check only (lint)
  -m               Show compiled in modules
  -q               Quiet-mode.  Suppress HTTP Header output.
  -s               Display colour syntax highlighted source.
  -v               Version number
  -w               Display source with stripped comments and whitespace.
  -z <file>        Load Zend extension <file>.
................................... failed



调试了 很多次,都这样 的 提示,不 知道如何解决,希望有经验者给予指点!

作者: guxiaochuan   发布时间: 2009-07-04

学习

作者: zxe   发布时间: 2009-11-23

你的命令地址错了,试试
/etc/init.d/php-fpm start  
或者
/usr/local/php5/bin/php-fpm start
主要是你的  php/sbin/php-fpm 文件有问题,可能是版本不同或者文件中的 “php_fpm_BIN=” 设定不同

作者: chunhay   发布时间: 2010-06-11