0

I ran the following command:

/usr/local/php/sbin/php-fpm start 

but the output is:

Usage: php-fpm [-n] [-e] [-h] [-i] [-m] [-v] [-t] [-p <prefix> ] [-c <file>] [-d foo[=bar]] [-y <file>] -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 -h This help -i PHP information -m Show compiled in modules -v Version number -p, --prefix <dir> Specify alternative prefix path to FastCGI process manager (default: /usr/local/webserver/php). -y, --fpm-config <file> Specify alternative path to FastCGI process manager config file. -t, --test Test FPM configuration and exit 

Is there anyone who has knowledge about this problem? Any advice appreciated!

Updated:

OS : CentOS 5.6 PHP: 5.3.6

I tried /usr/local/php/sbin/php-fpm and it works! Why?

I installed PHP with its source code.

10
  • 6
    AFAIK PHP-FPM is not a service/daemon. Why are you expecting start to work? Commented Aug 13, 2011 at 10:07
  • What do you want to do? Commented Aug 13, 2011 at 10:07
  • @Christian Sciberras: it is a daemon Commented Aug 13, 2011 at 10:08
  • @Pekka: obviously he is trying to start php-fpm daemon ;-) Commented Aug 13, 2011 at 10:11
  • 1
    @zerkms - Me the smart guy? Wasn't you the one blurting that PHP-FPM is a daemon? I simply told him start won't work with it. It was a comment, not an answer. You, on the other hand, went ahead explaining how start will magically work by putting the program name in an init script, without even explaining why. Stop being daft. Commented Aug 13, 2011 at 13:33

2 Answers 2

0

The problem you have is with the command you called:

/usr/local/php/sbin/php-fpm start 

The start part of it is not part of it's switches/parameters, so php-fpm gives you the usage information so you can actually look for what you tried to do, to correct your command call.

What do you wanted to do?

Are you looking how to configure your webserver to use the PHP-FPM implementation instead of FASTCGI?

17
  • 1
    omg, guys, he wanted to start php-fpm daemon Commented Aug 13, 2011 at 10:47
  • @zerkms: Which would not work for CLI. Hence my question: "What do you wanted to do?" Commented Aug 13, 2011 at 10:55
  • where do you see php cli? He is interacting with php-fpm Commented Aug 13, 2011 at 10:58
  • @zerkms: He is running the command in the shell, that is where I see CLI (Command Line Interface). Commented Aug 13, 2011 at 11:01
  • 1
    omg, guys, he wanted to start php-fpm daemon Me too! I just wanted to view a youtube video from my Nokia 1110i. But sadly it didn't work!!! Commented Aug 13, 2011 at 13:42
0

I'm going to attempt to answer the question based on a small (but major) assumption and not commment first because it may get lost in the bickering going on in comments.

It appears as though Foredoomed may be on FreeBSD, and has installed from ports. The question is lacking this useful information. On FreeBSD, there is no init.d and ports installed using /usr/local which is a major clue based on what I've seen so far.

So with that said, try this:

Edit /etc/rc.conf as root and add php_fpm_enable=”YES” to it, then save and close.

When you're ready to run php-fpm again, you start it using the rc.d scripts. As it's an installed program, it is not in /etc/rc.d, but in /usr/local/etc/rc.d:

Run the following: /usr/local/etc/rc.d/php-fpm start

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.