Accessing PHP-FPM's Status Page

Steve Holdoway steve at
Fri Jun 21 02:41:53 UTC 2013

On Thu, 2013-06-20 at 22:31 -0400, Schiz0 wrote:
> Hello list,
> I use php-fpm via fastcgi to handle my PHP scripts. I have that
> working successfully. PHP-FPM has a feature where it displays a status
> page, as mentioned here:
> I'd like to be able to access this through nginx. I tried setting my
> configuration to what I would expect to work, but, alas, it does not.
> Here's my configuration:
> The error I get when I try to browse to is:
> "File not found."
> in my browser, and in the nginx error log:
> 2013/06/20 22:29:51 [error] 85006#0: *13 FastCGI sent in stderr:
> "Primary script unknown" while reading response header from upstream,
> client: x.x.x.132, server:, request: "GET /fpm-status
> HTTP/1.1", upstream: "fastcgi://unix:/var/run/phpfpm.sock:", host:
> ""
> Nothing shows up in php-fpm's error log.
> Thanks for any help/suggestions on getting this working!

For me, 
location ~ ^/(status|ping|apc_info.php)$ {
    include fastcgi_params;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    fastcgi_pass backend;
    deny all;

pm.status_path = /status

in the pool definition works fine. 

I use a stub config just to manage access, which include a
load of monitoring stuff.



Steve Holdoway BSc(Hons) MNZCS
Skype: sholdowa

More information about the nginx mailing list