Zabbix using Nginx to do Web services
Logic diagram:
650) this.width=650; "Src=" Http://s4.51cto.com/wyfs02/M01/8C/F6/wKioL1iAV1LzKc_IAAE8OnYjAxY053.png-wh_500x0-wm_3 -wmp_4-s_2672750222.png "title=" Zabbix service proxy. png "alt=" wkiol1iav1lzkc_iaae8onyjaxy053.png-wh_50 "/>
Yum Nginx installed, the default default.conf file directly backup off, create a new zabbx.conf file,
#如果有报错看下nginx_log log error, Zabbix3.0.4nginx forwarding dependency./php-fpm-v
PHP 5.6.25, before the agent found useless error is not a misconfiguration, check the official website found to be the PHP-FPM version of the problem.
10.10.254.25 zabbix_server Server Nginx configuration:
$ cat zabbix.conf server{Listen 80; server_name _; Index index.html index.php; root/usr/local/nginx/html; Location ~. *\.php$ {include fastcgi_params; Fastcgi_pass 127.0.0.1:9000; Fastcgi_index index.php; Fastcgi_param script_filename $document _root$fastcgi_script_name;}
}
Outside the network machine agent Zabbix_server Nginx (the domain name I have changed, do not try):
Configuration of the 10.10.1.7nginx proxy:
[ops]$ cat zabbix34.ops.com.confserver { listen 80; server_name zabbix34.ops.com; allow 116.226.224.120/32; allow 180.167.73.37/32; allow 116.231.211.167/32; deny all; #zabbix3 .0.4 location / { proxy_pass http:/ /10.10.254.25/; proxy_set_header host $host; proxy_set_header X-Real-IP $remote _addr; proxy_set_header x-forwarded-for $proxy _add_x_forwarded_for; }}
This article is from the "LINUX Super Dream" blog, make sure to keep this source http://215687833.blog.51cto.com/6724358/1893156
Zabbix using Nginx to do Web services