nagios如何实现对个别用户隐藏部分服务信息。
1、添加测试用户
htpasswd /usr/local/nagios/etc/htpasswd.users user
2、将测试用户添加到联系人。
define contact{ contact_name test use generic-contact alias test }
3、将联系人添加到允许查看的个别服务中(define service)。注意不能写入define host,写入host里面就能看见该主机的全部服务了。
define service { use web host_name web-test service_description 80_Port_Status normal_check_interval 1 notifications_enabled 0 check_command check_tcp!80 contacts test }
这样就能想让test用户看什么服务,就只能看什么服务。
亿速云「云服务器」,即开即用、新一代英特尔至强铂金CPU、三副本存储NVMe SSD云盘,价格低至29元/月。点击查看>>
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。