Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NGINX监控无返回值:python nginx.py -p 80 -k accepts #42

Open
spritluo opened this issue Aug 15, 2018 · 3 comments
Open

NGINX监控无返回值:python nginx.py -p 80 -k accepts #42

spritluo opened this issue Aug 15, 2018 · 3 comments

Comments

@spritluo
Copy link

NGINX监控无返回值:python nginx.py -p 80 -k accepts
没有返回值,也没有报错,能帮忙看看嘛?谢谢了
ERROR:
[2018-08-16 00:54:29] ERROR
Traceback (most recent call last):
File "nginx.py", line 186, in main
value = ngx.get_item_tval(key, uri)
File "nginx.py", line 144, in get_item_tval
val = self.get_value(key, uri, port=port, iphost=iphost)
File "nginx.py", line 127, in get_value
(value, code) = self._file_cache.get_val_from_json(key)
File "/usr/lib/python2.7/site-packages/qiueer/python/filecache.py", line 38, in get_val_from_json
resobj = str(alllines[1]).strip()
IndexError: list index out of range

@qiueer
Copy link
Owner

qiueer commented Aug 23, 2018

nginx里面需要增加如下的配置:

    location /ngx_status
    {
        stub_status on;
        access_log off;
        allow 127.0.0.1;
        deny all;
    }

@YellowDong
Copy link

你好 请问现在项目能跑起来了吗?那个主配置文件zabbix_agentd.conf怎么配置,配置完是怎么重启服务的 谢谢

@qiueer
Copy link
Owner

qiueer commented Feb 22, 2019

@YellowDong
查看使用:https://github.com/qiueer/zabbix/tree/master/All%20In%20One
查阅脚本:zabbix/All In One/zabbix_extend_init.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants