Chinaunix首页 | 论坛 | 博客
  • 博客访问: 361016
  • 博文数量: 36
  • 博客积分: 570
  • 博客等级: 中士
  • 技术积分: 1042
  • 用 户 组: 普通用户
  • 注册时间: 2011-09-08 20:53
文章分类
文章存档

2015年(1)

2014年(1)

2013年(14)

2012年(10)

2011年(10)

分类: LINUX

2012-08-03 10:23:46

Linux平台

1.       Linux上安装 ProLiantSupportPack

64CentOS 6.2为例

   wget

 下载 repo文件:

   sh bootstrap.sh ProLiantSupportPack -a x86_64 -d RHEL -r 6.2Server

 安装以下包

yum clean all

yum makecache

yum install hp-health

yum install hpacucli

 

下载安装 nagios-plugin

   ./configure –prefix=/usr/local/nagios –with-nagios-user=nagios –with-nagios-group=nagios

   make

   make install

下载安装 nrpe

   ./configure –prefix=/usr/local/nagios

   Make all

   Make install-plugin

   Make install-daemon

   Make install-daemon-config

   如果要以超级进程的方式启动则需要:

   Make install-xinetd

 /etc/services 添加下一行:

nrpe            5666/tcp       # nrpe

/etc/xinetd.d/nrpe:

加入监控主机的地址

Only_from   =  127.0.0.0  nagios_server_ip

 

chkconfig nrpe on

/etc/init.d/xinetd restart

 

下载安装 check_hpasm

./configure prefix=/usr/local/nagios --with-nagios-user=nagios --with-nagios-group=nagios --with-degrees=celsius --enable-hpacucli --enable-hwinfo --enable-extendedinfo --enable-perfdata

  make

  make install


配置 nrpe

/usr/local/nagios/etc/nrpe.cfg

command[check_hp_hardware]=/usr/local/nagios/libexec/check_hpasm --perfdata short

 

iptable开放 tcp 5666端口

 

nagios用户加入到 wheel

Gpasswd –a nagios wheel

 

编辑sudo配置文件

Visudo

将下一行的注释去掉

%wheel  ALL=(ALL)       NOPASSWD: ALL

将下一行加上注释

Defaults    requiretty

 

Nagios 服务器上配置

定义主机、定义服务

阅读(5472) | 评论(0) | 转发(0) |
0

上一篇:Nagios 实施步骤

下一篇:openvz的初始化

给主人留下些什么吧!~~