Incorrect Duration Time

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
rlinux57
Posts: 324
Joined: Mon Dec 08, 2014 12:03 am

Incorrect Duration Time

Post by rlinux57 »

Hi All,

I am curious about the duration time of my node services in nagios server. As i have restarted the server, When it came back the duration time of some services are less than one minute such as 0d 0h 0m 33s and some of the services duration time 270d 12h 40m 41s . Whats wrong with the nagios, It doesn't monitor the real time duration. Please find attached screenshot for your reference.

I am using nagios 4.4.1 and nrpe v2.15

Thank you,
Regards,
rlinux57
Attachments
nagios.png
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Incorrect Duration Time

Post by scottwilkerson »

The duration is how long it has been in the current state. If the state changes on these it would reset.

Also, there are retain_status_information and retain_nonstatus_information directives for host/service objects that can be set on the service that would reset these if disabled
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
rlinux57
Posts: 324
Joined: Mon Dec 08, 2014 12:03 am

Re: Incorrect Duration Time

Post by rlinux57 »

Hi again,

I didn't set any retain status for services and host. Could you explain the retain status and nonstatus and by default which one is used by nagios server. And how do i get rid off this issue ?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Incorrect Duration Time

Post by scottwilkerson »

The definition of both is here and they are enabled by default
https://assets.nagios.com/downloads/nag ... tions.html

First, I would look in the Alerts -> History report to see if these services changed state recently.

If they did, this would explain everything.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
rlinux57
Posts: 324
Joined: Mon Dec 08, 2014 12:03 am

Re: Incorrect Duration Time

Post by rlinux57 »

History report of PING Service:
When host is down:

Code: Select all

[09-05-2018 16:29:27] SERVICE ALERT: Server-01;PING;CRITICAL;SOFT;1;PING CRITICAL - Packet loss = 100%
When it comes up:

Code: Select all

[09-05-2018 16:34:21] SERVICE ALERT: Server-01;PING;OK;SOFT;1;PING OK - Packet loss = 0%, RTA = 0.59 ms
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Incorrect Duration Time

Post by scottwilkerson »

Ok, at that time the duration will start again at 0d 0h 0m 0s

Now, if your server recovered before the other items were checked again, they will still show the longer duration because they never experienced a non-OK state
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
rlinux57
Posts: 324
Joined: Mon Dec 08, 2014 12:03 am

Re: Incorrect Duration Time

Post by rlinux57 »

But it shows critical PING;CRITICAL . When its recovered, the state changed and duration time still the same before going down. Why ?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Incorrect Duration Time

Post by scottwilkerson »

I just looked again and see you are running 4.4.1

There were several bugs in 4.4.1 that relate to this that are fixed in 4.4.2
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
rlinux57
Posts: 324
Joined: Mon Dec 08, 2014 12:03 am

Re: Incorrect Duration Time

Post by rlinux57 »

Okay. How could i Upgrade it and Is it necessary to upgrade nagios plugins on server and nrpe on host machines. Please mention the link as well.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Incorrect Duration Time

Post by scottwilkerson »

rlinux57 wrote:Okay. How could i Upgrade it and Is it necessary to upgrade nagios plugins on server and nrpe on host machines. Please mention the link as well.
Only Core would need upgrading, here is the documentation
https://support.nagios.com/kb/article/n ... e-797.html
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked