nagios

Apache套件    yum install httpd
Gcc編譯器       yum install gcc
Glibc函式庫    yum install glibc glibc-common
GD函式庫                         yum install gd gd-devel

yum install nagios nagios-plugins-all nrpe

下載Nagios及其Plugins,目前最新穩定版本分別為3.0.6與1.4.13
為了讓Nagios伺服器可以監看遠端Linux主機,需要額外安裝NRPE套件

測試設定檔無誤    
            
nagios -v /etc/nagios/nagios.cfg

啟動 nagios            

service nagios start

查看狀態

nagiostats

Web 界面

vi /etc/httpd/conf.d/nagios.conf

ScriptAlias /nagios/cgi-bin "/usr/lib/nagios/cgi"

<Directory "/usr/lib/nagios/cgi">
#  SSLRequireSSL
   Options ExecCGI
   AllowOverride None
   order allow,deny
   Allow from all
#  order deny,allow
#  Deny from all
   Allow from 127.0.0.1 192.168.1.0/24
   AuthName "Nagios Access"
   AuthType Basic
   AuthUserFile /etc/nagios/htpasswd
   Require valid-user
</Directory>

Alias /nagios "/usr/share/nagios"

<Directory "/usr/share/nagios">
#  SSLRequireSSL
   Options None
   AllowOverride None
   order allow,deny
   Allow from all
#  order deny,allow
#  Deny from all
   Allow from 127.0.0.1 192.168.1.0/24
   AuthName "Nagios Access"
   AuthType Basic
   AuthUserFile /etc/nagios/htpasswd
   Require valid-user
</Directory>
agios.conf

apachectl graceful

htpasswd -c   /etc/nagios/htpasswd nagiosadmin

登入 http://ip/nagios



[本日志由 tseng 于 2009-05-06 01:13 PM 编辑]
文章来自: 本站原创
引用通告: 查看所有引用 | 我要引用此文章
Tags: nagios安裝
评论: 0 | 引用: 0 | 查看次数: 27635
发表评论
昵 称:
密 码: 游客发言不需要密码.
内 容:
验证码: 验证码
选 项:
虽然发表评论不用注册,但是为了保护您的发言权,建议您注册帐号.
字数限制 1000 字 | UBB代码 开启 | [img]标签 关闭