Hosts check stuck in pending

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.
maddog123
Posts: 7
Joined: Mon Jul 27, 2015 3:44 pm

Hosts check stuck in pending

Post by maddog123 »

I'm using Nagios® Core™ 4.1.0rc1 running on 64 bit Cent OS 5.11
When I check the Map option i see 2/3 of the map pending and the other 1/3 up and green
the services are all OK in status the logs don't show anything unusual the same hosts that are in pending state also on the Hosts listing dont show and Duration time just "???" in that field. The only way i can get the pending to change is to Re-schedule the next check of this host is the only way i can get the map display to show each host up instead of pending.
I have searched Google and the forum posts And only see something like this in Nagios XI but I dont have the option it talks about to change this.

https://support.nagios.com/forum/viewto ... 16&t=27673

Any help would be greatly appreciated
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Hosts check stuck in pending

Post by jdalrymple »

This is typical behaviour of a host that doesn't have a valid host check defined. Do you?

It might be helpful to look at the host definition in objects.cache for a host stuck in PENDING. Clues are usually easy to spot there.
maddog123
Posts: 7
Joined: Mon Jul 27, 2015 3:44 pm

Re: Hosts check stuck in pending

Post by maddog123 »

Every host has a
check_command check-host-alive

See my host.cfg attached
Attachments
Default Linux Host Template ICCC Network.docx
(14.85 KiB) Downloaded 406 times
maddog123
Posts: 7
Joined: Mon Jul 27, 2015 3:44 pm

Re: Hosts check stuck in pending

Post by maddog123 »

here is my host.cache file
Attachments
NAGIOS OBJECT CACHE FILE.docx
(24.05 KiB) Downloaded 287 times
maddog123
Posts: 7
Joined: Mon Jul 27, 2015 3:44 pm

Re: Hosts check stuck in pending

Post by maddog123 »

They look like the same setup for one the is show up correctly and another that is showing up correctly?
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Hosts check stuck in pending

Post by jdalrymple »

Everything looks OK. Next step is to peer at your nagios.log file for anomalies. Something is preventing your checks from running and it's hard to say what. nagios.log may have clues - and additionally it could be a problem in your nagios.cfg. Can you shoot that our way for review?

Also - anecdotally and totally not related, why bleeding edge Nagios on such an old version of Cent?
maddog123
Posts: 7
Joined: Mon Jul 27, 2015 3:44 pm

Re: Hosts check stuck in pending

Post by maddog123 »

i had it available at the time the Linux box and it wasn't being used plan to update this summer but haven't gotten around to it.

here are the two files

thank you for your help!!
Attachments
Log fileNagios.docx
(13.78 KiB) Downloaded 217 times
NAGIOS_CFG.docx
(40.92 KiB) Downloaded 225 times
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Hosts check stuck in pending

Post by tgriep »

It could be that your retention.dat file is corrupt. You could delete it but the consequences of that is your system will lose all of the notes, downtime, duration, and all of your checks will start over like it is a new system.
If you are willing to to this, here is how to do that.
In a shell as root run the following

Code: Select all

service nagios stop
rm /usr/local/nagios/var/retention.dat
service nagios start
Let us know if the hosts start up after doing this.
Be sure to check out our Knowledgebase for helpful articles and solutions!
maddog123
Posts: 7
Joined: Mon Jul 27, 2015 3:44 pm

Re: Hosts check stuck in pending

Post by maddog123 »

that seemed to do the trick thank you, does that have to be done once in awhile?
User avatar
tgriep
Madmin
Posts: 9177
Joined: Thu Oct 30, 2014 9:02 am

Re: Hosts check stuck in pending

Post by tgriep »

Shouldn't have to be done at all unless that file was corrupted.
Possible causes are power outages, drive failure or the drive filling up, etc.
Shall I close the post?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked