nagios using nsca

Download package and Install nsca package
nagios-nsca-2.7.2-2.el5.rf.x86_64.rpm 
libmcrypt-2.5.7-1.2.el5.rf.i386.rpm 
nagios-nsca-client-2.7.2-2.el5.rf.i386.rpm 
Install the package
[root@fazries.com nagios]# yum localinstall nagios-nsca-2.7.2-2.el5.rf.x86_64.rpm libmcrypt-2.5.7-1.2.el5.rf.i386.rpm nagios-nsca-client-2.7.2-2.el5.rf.i386.rpm 
configure nsca server, at nsca.conf
server_port=5667 
command_file=/var/nagios/rw/nagios.cmd 
alternate_dump_file=/var/nagios/rw/nsca.dump 
aggregate_writes=0 
append_to_file=0 
max_packet_age=30 
chown nsca.cfg
[root@fazries.com nagios]# chown nagios:nagios nsca.cfg 
configure xinetd
 
[root@fazries.com xinetd.d]# pwd 
/etc/xinetd.d 
[root@fazries.com xinetd.d]# cat nsca 
# default: off 
# description: NSCA (Nagios Service Check Acceptor) 
service nsca 
{ 
        flags = REUSE 
        type = UNLISTED 
        port = 5667 
        socket_type = stream 
        wait = no 
        user = nagios 
        group = nagios 
        server = /usr/sbin/nsca 
        server_args = -c /etc/nagios/nsca.cfg --inetd 
        log_on_failure += USERID 
        disable = no 
        only_from = 127.0.0.1 
} 
Add nsca services
[root@fazries.com xinetd.d]# vi /etc/services 
nsca 5667/tcp # NSCA 
[root@fazries.com xinetd.d]# /etc/init.d/xinetd restart 
Stopping xinetd: [FAILED] 
Starting xinetd: [ OK ] 
Cek active port
[root@fazries.com xinetd.d]# netstat -tnl | grep 5667 
tcp 0 0 0.0.0.0:5667 0.0.0.0:* LISTEN 
Adding Host for nagios
[root@fazries.com objects]# touch host.cfg 
[root@fazries.com objects]# vim host.cfg 
[root@fazries.com objects]# cat host.cfg 
define host 
{ 
use generic-host 
host_name localhost 
address 127.0.01 
active_checks_enabled 0 
passive_checks_enabled 1 
} 

[root@fazries.com objects]# chown nagios:nagios host.cfg 
[root@fazries.com objects]# chmod 664 host.cfg 
[root@fazries.com objects]# pwd 
/etc/nagios/objects 
[root@fazries.com objects]# chcon --reference=commands.cfg * 
Restart nsca services
[root@fazries.com objects]# /etc/init.d/nsca start 
Starting Nagios NSCA daemon (nsca): [ OK ] 
[root@fazries.com objects]# /etc/init.d/nagios start 
nagios is stopped 
Configuration validation failed [FAILED] 
[root@fazries.com objects]# setenforce 0 
[root@fazries.com objects]# /etc/init.d/nagios start 
nagios is stopped 
Starting nagios: [ OK ]

Comments

  1. The good and the bad of a casino - Dr.MCD
    The bad of a casino. When you are a gambler, you are playing casino games 태백 출장마사지 for free,” said the 동두천 출장샵 casino 고양 출장안마 operator. When 상주 출장샵 you start, you will 양산 출장샵 win no

    ReplyDelete
  2. congchar0diu-ji_Erie Jill Smith link
    limengunscor

    ReplyDelete

Post a Comment