系统为ubuntu,在usr/etc/sites-enabled/中编辑nginx配置文件


server_name demo.com;
location ~^/status$ {

        #auth_basic "status page";
        #fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $fastcgi_script_name;
        include fastcgi_params;
        fastcgi_pass unix:/var/run/php5-fpm.sock;
        #如果是端口请用 fastcgi_pass 127.0.0.1:9000;
    }

另外需要在/etc/php5/fpm/pool.d/www.conf中修改一项,把status打开

pm.status_path = /status

当然可以看看fpm中关于staus的一些参数说明。

然后重启fpm 和nginx

servie php5-fpm start|status|stop

service nginx relaod

成功后可以看到如下图
php-fpm status状态配置显示

传送门

相关文章:

  • 2021-11-06
  • 2021-12-06
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-27
  • 2021-07-27
猜你喜欢
  • 2022-12-23
  • 2021-07-24
  • 2021-07-25
  • 2021-09-11
  • 2021-11-04
  • 2021-08-18
  • 2022-12-23
相关资源
相似解决方案