最近我写了关于naigos监控的安装与配置的技术文档,公司运维按照我的文档部署naigos,发现不能发送报警邮件,经过我的检查,发现问题如下:
1、hosts里的配置
- [root@nagios ~]# cat /etc/hosts
- # Do not remove the following line, or various programs
- # that require network functionality will fail.
- 127.0.0.1 localhost.localdomain localhost
- ::1 localhost6.localdomain6 localhost6
- 172.16.4.3 nagios.com nagios ##一定要有本机的ip对应
3、去nagios的web里,选择报警的服务(如果httpd),
点击http旁边的这个摁钮,如果你看到notification状态为disabled 那么你可以选择右侧的,然后选择commit 。出现下面对话框
- [root@nagios var]# tail -f nagios.log
- [1326419317] Auto-save of retention data completed successfully.
- [1326422917] Auto-save of retention data completed successfully.
- [1326424408] EXTERNAL COMMAND: ENABLE_SVC_NOTIFICATIONS;henan-cunchu;HTTP
- [1326424434] Caught SIGTERM, shutting down...
- [1326424434] Successfully shutdown... (PID=6823)
- [1326424434] Nagios 3.3.1 starting... (PID=25398)
- [1326424434] Local time is Fri Jan 13 11:13:54 CST 2012
- [1326424434] LOG VERSION: 2.0
- [1326424434] Finished daemonizing... (New PID=25399)
- [1326424464] SERVICE NOTIFICATION: nagiosadmin;henan-cunchu;HTTP;CRITICAL;notify-service-by-email;?.?杩..
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。