背景原因:
因刚换工作,突然发现nginx status状态没有被监控,然后在准备添加nginx status的时候,发现之前同事在编译nginx的时候没有编译nginx status模块,可恶,常用的模块都不编译.主要两部分,
第一部分:编译nginx模块
第二部分:zabbix 监控nginx status,其实之前写过,稍微把监控方式优化了下。
一、nginx 编译模块
1.下载nginx安装包
root@gcs:/home/steven# wget http://nginx.org/download/nginx-1.6.3.tar.gz
--2015-09-09 17:27:40-- http://nginx.org/download/nginx-1.6.3.tar.gz
Resolving nginx.org (nginx.org)... 206.251.255.63, 2606:7100:1:69::3f
Connecting to nginx.org (nginx.org)|206.251.255.63|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 805253 (786K) [application/octet-stream]
Saving to: ‘nginx-1.6.3.tar.gz’
100%[============================================================================================================>] 805,253 569KB/s in 1.4s
2015-09-09 17:27:42 (569 KB/s) - ‘nginx-1.6.3.tar.gz’ saved [805253/805253]
root@gcs:/home/steven# ls
nginx-1.6.3.tar.gz
root@gcs:/home/steven#
[Read More]