Nagios can know how much time has been down the devices?

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.
Locked
Jessuzz94
Posts: 162
Joined: Thu Jun 04, 2015 12:08 pm

Nagios can know how much time has been down the devices?

Post by Jessuzz94 »

For example, if nagios is monitoring one site with servers, and the energy shut down all servers and the nagios server, when it restart, in the reports nagios can view the information about the down time of the servers monitored?, or lost the information when it shutdown too?
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Nagios can know how much time has been down the devices?

Post by jdalrymple »

Availability report. It's on the status page for each host and service.
Jessuzz94
Posts: 162
Joined: Thu Jun 04, 2015 12:08 pm

Re: Nagios can know how much time has been down the devices?

Post by Jessuzz94 »

Yeah, i think it doesnt work, i put a test: i shut down the switch for some minutes and i did the "Trends" report and work

But i do another test,i shutted down nagios server and the switch monitored, so, i wanted that nagios report the time that the switch was down, but it doesnt did. its like was up all time, i think if nagios is down it cant report the informations of the time states :c
Attachments
second test
second test
switch1.png (6.85 KiB) Viewed 2195 times
first test
first test
switch.png (7.35 KiB) Viewed 2195 times
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Nagios can know how much time has been down the devices?

Post by jdalrymple »

This is most likely due to your retry_interval and max_check_attempts. A host isn't down until it's in a HARD down state. If it stays SOFT it won't show up as an outage on the availability report just because we assume it was a "hiccup" - hence max_check_attempts purpose.
Jessuzz94
Posts: 162
Joined: Thu Jun 04, 2015 12:08 pm

Re: Nagios can know how much time has been down the devices?

Post by Jessuzz94 »

how can i configure the objects definitions for the host to do the inmediatly hard state when the host downs?
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Nagios can know how much time has been down the devices?

Post by jdalrymple »

set max_check_attempts to 1:
max_check_attempts: This directive is used to define the number of times that Nagios will retry the host check command if it returns any state other than an OK state. Setting this value to 1 will cause Nagios to generate an alert without retrying the host check. Note: If you do not want to check the status of the host, you must still set this to a minimum value of 1. To bypass the host check, just leave the check_command option blank.
Jessuzz94
Posts: 162
Joined: Thu Jun 04, 2015 12:08 pm

Re: Nagios can know how much time has been down the devices?

Post by Jessuzz94 »

Oh okay, i will test!, very thanks!, i will read the objects definitions
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: Nagios can know how much time has been down the devices?

Post by jdalrymple »

No problem. Here is a link to all the object definitions:

http://nagios.sourceforge.net/docs/nagi ... tions.html is the objects definition page - however sourceforge is having issues at the moment so it may not be available until they get their problems resolved.

Is it OK to lock this thread?
Jessuzz94
Posts: 162
Joined: Thu Jun 04, 2015 12:08 pm

Re: Nagios can know how much time has been down the devices?

Post by Jessuzz94 »

Yeah is saw that is no connection, yes, thanks!
Locked