NRDP

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: NRDP

Post by rkennedy »

Thanks @eloyd!

@peter19x - that should do the trick, let us know if you have further questions.
Former Nagios Employee
peter19x
Posts: 119
Joined: Tue Dec 08, 2015 10:16 am

Re: NRDP

Post by peter19x »

Hello,

Thanks @eloyd

I have added the apache user in the nagcmd group although the command did not work and gave the below:

Code: Select all

[root@GSIP_MGNT_A checkresults]# usermod apache -a -G nagcmd,nagios
usermod: user 'nagcmd,nagios' does not exist
I have used the command below

Code: Select all

[root@GSIP_MGNT_A checkresults]# usermod -a -G nagcmd apache
[root@GSIP_MGNT_A checkresults]# groups apache
apache : apache nagcmd checkmk
and now the files created are in the format below and there is no more errors!

Code: Select all

-rwxrwx---. 1 apache nagcmd 228 Jun 27 09:53 coRycNj
Now I am getting the error in the nagios.log

/usr/local/nagios/var/nagios.log

Code: Select all

[1467022444] Error: Got check result for service 'dbstatus' on host 'sbc-siplab02'. Unable to find service
So I have added my host that is sending the passive checks along with the service dbstatus In a .cfg file as below:

Code: Select all

define host{
        host_name               sbc-siplab02
        address                 172.25.25.11
        check_command           check-host-alive
        check_period            24x7
        check_interval          5
        retry_interval          1
        max_check_attempts      5
        contact_groups          admins
        notification_interval   *
        notification_period     workhours
        }

define service{
        host_name                       sbc-siplab02
        service_description           dbstatus
        check_period                    24x7
        max_check_attempts         5
        normal_check_interval       5
        retry_check_interval          1
        }

Pardon my question if it is too basic, but I am not sure what 'check_command' should be added in the service dbstatus or if there is something else for passive checks that should be added

and when I run

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
I get the following error:
Error: Could not register service (config file '/usr/local/nagios/etc/objects/store.cfg', starting on line 33)

line 33 is the dbstatus service I have added.

My Passive check command that I send from the server is the below:

Code: Select all

/home/nagiosscripts/send_nrdp.sh -u http://172.25.28.119/nrdp/ -t nb65fgtadI39 -H "sbc-siplab02" -s "dbstatus" -S 2 -o "DB status is DOWN"
Any idea what is missing in this scenario ?

Thanks,
Peter
User avatar
eloyd
Cool Title Here
Posts: 2190
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: NRDP

Post by eloyd »

I may have messed up my command, but I'm glad you got it working. I'm guessing the mods will want you to open a new topic on this latest development, though, to keep things separate.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoyd
I'm a Nagios Fanatic! • Join our public Nagios Discord Server!
peter19x
Posts: 119
Joined: Tue Dec 08, 2015 10:16 am

Re: NRDP

Post by peter19x »

Sure,

Thank you for the help again!

I am fine with closing this thread now.

Best Regards,
Peter
Locked