温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

centos yum搭建nagios

发布时间:2020-08-03 18:10:29 来源:网络 阅读:257 作者:yuandken 栏目:移动开发

一,定义yum非官方库

1, vi /etc/yum.repos.d/dag.repo

   在这之中加入以下内容:

[dag]
name= Linux
baseurl=http://apt.sw.be/redhat/el$releasever/en/$basearch/dag
gpgcheck=1
enabled=1
gpgkey=http://dag.wieers.com/packages/RPM-GPG-KEY.dag.txt

2.    手工下载RPM-GPG-KEY.dag.txt(#wget http://dag.wieers.com/packages/RPM-GPG-KEY.dag.txt)

rpm --import RPM-GPG-KEY.dag.txt


二,安装

1,安装nagios

yum -y install nagios

service httpd restart

htpasswd -c /etc/nagios/htpasswd.users nagios   创建用户 nagios 用于登录nagios

2,安装 nagios-plugins,否则连localhost都无法监控

yum -y install nagios-plugins

(注意关闭selinux)


可以通过 web访问 nagios了


三,汉化

 wget  http://sourceforge.net/projects/nagios-cn/files/sourcecode/zh_CN%203.2.3/nagios-cn-3.2.3.tar.bz2

 tar jxvf nagios-cn-3.2.3.tar.bz2

 cd nagios-cn-3.2.3

./configure

make all

make install





向AI问一下细节

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI