Page 1 of 1

Warnings show negative duration

Posted: Mon Dec 10, 2012 1:35 am
by BWNet
Hi everybody. I'm experiencing an issue sind last Friday, that I can't solve.
Every checked service that is in either warning or critical state shows a negative time value in the "duration" field. Also there are no more notifications sent out for these events. The screenshot below shows this issue. The first warning is a "new" one with a duration of -19s. The second warning is older (older than last Friday) so it still shows the correct duration. Every new service in warning/critical state shows the negative duration...
change.JPG
Also, when I take a look at the advanced tab of this service, it shows that the last notification sent was 01/01/1970 (which is not correct).
screen2.JPG
However, if I look up this service in Nagios Core (via the "See this service in Nagios core" link), the correct state duration is shown...
screen3.JPG
Right now I don't know where to look for a solution...is there somebody who knows a way for fixing it?

EDIT:
I just realised that my NagiosXI webinterface is 7 hours behind my server time. When I have a look at some tables that have an "Last updated" below them, it reads: "Last Updated: 10/12/2012 00:43:02". When I logon to the NagiosXI Server using ssh and execute date it says "Mon Dec 10 07:44:00 CET 2012" (which is correct).

Thanks in advance,
Benjamin

Re: Warnings show negative duration

Posted: Mon Dec 10, 2012 10:37 am
by scottwilkerson
Can you go to Admin -> System Profile and attach it here.

I am guessing you may not have synced times between the system time and the php.ini

you may also need to update the server timezone and time, instructions in this post
http://support.nagios.com/forum/viewtop ... ime#p24962

Re: Warnings show negative duration

Posted: Wed Dec 12, 2012 1:08 am
by BWNet
Hi,

thanks for the help. You were right, the Error was in the php.ini. There my system was on Chicago time-zone while the server itself runs on european time.
Thanks for the hint :-)