Zabbix监控nginx
跳到导航
跳到搜索
office
nginx -V 2>&1 | grep -o with-http_stub_status_module. Example configuration of Nginx: 直接加在 nginx.conf location = /basic_status { stub_status; allow 127.0.0.1; allow ::1; deny all; } 一般我放的位置 参数不一致 不过官方用过了 爽 可用 server { listen 80 default_server; listen [::]:80 default_server; server_name _; #charset koi8-r; #access_log logs/host.access.log main; #evan location /nginx_stat { stub_status on; access_log off; allow 127.0.0.1; deny all; } #evan 官方模板有 4个图 只有一个 Nginx: Connections by state Nginx: Connections by state 900 200 正常 Nginx: Connections per second 900 200 正常 Nginx: Memory usage 900 200 正常 Nginx: Requests per second 还有报警的要改 可以用 666 告警信息: Nginx: Failed to fetch stub status page (or no data for 30m) 告警项目:web.page.get["localhost","basic_status","80"] 最后添加官方模板 Template App Nginx by Zabbix agent