CentOS6.0最小化安装系统后搭建nagios监控平台
- yum -y install gcc gcc-c++ glibc glibc-common gd gd-devel automake autoconf libtool make
- yum -y install setuptool ntsysv system-config-network-tui system-config-securtiylevel-tui system-config-securitylevel-tui
- yum -y install httpd MySQL mysql-server mysql-devel mysql perl mysql-server perl-DBI perl-DBD-MySQL perl-Time-HiRes
- yum -y install php-devel php php-pear php-mysql php* libssh3 libssh3-devel glibc glibc-common gd gd-devel yum -y install rrdtool rrdtool-perl openssl-devel crontabs xinetd sudo wget vim python gettext
- yum -y install net-snmp net-snmp-libs net-snmp-utils
- vi .bashrc
- vi /etc/profile
- vi /etc/sysconfig/selinux
- useradd nagios
- mkdir -p /usr/local/nagios
- chown nagios.nagios /usr/local/nagios
- usermod -s /sbin/nologin nagios
- groupadd nagcmd
- usermod -G nagcmd nagios
- usermod -G nagcmd apache
- tar zxf nagios-3.4.1.tar.gz
- cd nagios-3.4.1.tar.gz
- cd nagios
- ./configure --prefix=/usr/local/nagios --with-nagios-user=nagios --with-nagios-group=nagios --with-command-group=nagcmd
- make all
- make install
- make install-init
- make install-commandmode
- make install-config
- vi vi /usr/local/nagios/etc/objects/contacts.cfg
- make install-webconf
- htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin vi /usr/local/nagios/etc/objects/contacts.cfg
- cd ..
- tar zxf nagios-plugins-1.4.16.tar.gz
- cd nagios-plugins-1.4.16
- ./configure --with-nagios-user=nagios --with-nagios-group=nagios
- make && make install
- chkconfig --add nagios
- chkconfig nagios on
- chkconfig httpd on
- chkconfig mysqld on
- vi /etc/httpd/conf/httpd.conf
- service httpd start
- service nagios start
- service mysqld start
- /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
- vi ~/.bashrc
- alias check='/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg'
- source ~/.bashrc
- check
- tar zxf nrpe-2.13.tar.gz
- cd nrpe-2.13
- ./configure --prefix=/usr/local/nagios/
- make all
- make install-plugin
- netstat -lantpue
- ll /usr/local/nagios/libexec/check_nrpe
- /sbin/iptables -I INPUT -p tcp --dport 80 -j ACCEPT
- /etc/rc.d/init.d/iptables save
- service iptables restart
- http://ip/nagios
创新互联主营香河网站建设的网络公司,主营网站建设方案,App定制开发,香河h5微信平台小程序开发搭建,香河网站营销推广欢迎香河等地区企业咨询
附件:http://down.51cto.com/data/2360984
网站题目:CentOS6.0最小化安装系统后搭建nagios监控平台
转载源于:http://ybzwz.com/article/jsjgce.html