当前位置: 代码迷 >> 综合 >> Nagios的安装和基本配置(三:Nagios-Client的安装)
  详细解决方案

Nagios的安装和基本配置(三:Nagios-Client的安装)

热度:54   发布时间:2023-11-26 10:30:40.0

任务三、Nagios-Client的安装

3.1、关闭防火墙和selinux

注:

#systemctl stop firewalld.service

#systemctl disable firewalld.service

#vi /etc/selinux/config

3.2、配置环境

#yum install gcc glibc-common -y

#yum install gd gd-devel openssl openssl-devel -y

#yum install php php-gd perl net-tools -y

3.3、安装Nagios-plugin

添加nagios用户

#useradd -s /sbin/nologin nagios

解压安装

#tar zxvf Nagios-plugins-2.2.1.tar.gz

#cd Nagios-plugins-2.2.1

#./configure –with-nagios-user=Nagios –with-nagios-group=Nagios

#make $$ make install

3.4、安装nrpe

#tar zxvf nrpe-3.2.1.tar.gz

#cd nrpe-3.2.1

#./configure –with-nrpe-user=Nagios \

--with-nrpe-group=Nagios \

--with-nagios-user=Nagios \

--with-nagios-group=Nagios \

--enable-command-args \

--enable-ssl

#make all

#make install-plugin

#make install-daemon

#make install-daemon-config

#ls /usr/local/nagios/libexec/ |grep check_nrpe

#/usr/local/Nagios/bin/nrpe -d -c /usr/local/Nagios/etc/nrpe.cfg

  相关解决方案