客户端配置:
vim /usr/local/php/etc/php-fpm.d/www.conf 开启状态
将pm.status_path = /phpfpmstatus前的#号注释掉
/etc/init.d/php-fpm restart
同样在客户端开启nginx.conf里面的php-status状态
server {
listen 80;
server_name _;
root /dev/null;
location /nginx-status {
# Enable nginx status
stub_status on;
# I do not need logs
access_log off;
allow 10.0.0.0/8;
allow 127.0.0.1;
deny all;
}
location /phpfpmstatus {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fcgi.conf;
# I do not need logs
access_log off;
allow 127.0.0.1;
allow 10.0.0.0/8;
deny all;
}
}
nginx -t&&nginx -s reload
mkdir -p /etc/zabbix/monitor_scripts/ && cd /etc/zabbix/monitor_scripts/