Page 1 of 1

Is daylight saving time screwing up availabity report ?

Posted: Wed Apr 02, 2014 3:14 pm
by mmazerolle
Hi all,

For the past 2 or 3 months we have been producing availability reports using Nagios 3.4.1 to the various entities in our organization. It has been working every month except last month (March).

Every entity in our organization have hostgroups identifying theirs hosts and timeperiods defining the "working hours" of that entity. So Hostgroup "Entity A" has 12 hosts with various number of services check each and a corresponding timeperiod defining that "Entity A" is working from Monday to Saturday (all day). They are closed on Sunday so I don't want downtime on Sundays to be considered.

When I produce the report the "% Time Undetermined" produces a value of 1151482151916950.500% and Undetermine Time of "1158050441d 6h 0m 16s" for certain hostgroup in March (and so far, only March). We've been generating the reports since last December.

Can this be related to the change of time in March ?

Thanks for your quick reply.

Marc

Re: Is daylight saving time screwing up availabity report ?

Posted: Thu Apr 03, 2014 9:05 am
by tmcdonald
Does the time in PHP match up with your system time?

Code: Select all

grep "date.time" /etc/php.ini
php -r "echo date(DATE_RFC2822);"
date

Re: Is daylight saving time screwing up availabity report ?

Posted: Thu Apr 03, 2014 9:17 am
by mmazerolle
Apparently it does.

Code: Select all

sh-4.1$     grep "date.time" /etc/php.ini
; http://www.php.net/manual/en/datetime.configuration.php#ini.date.timezone
date.timezone = America/Montreal
sh-4.1$     php -r "echo date(DATE_RFC2822);"
Thu, 03 Apr 2014 10:15:50 -0400
sh-4.1$     date
Thu Apr  3 10:15:51 EDT 2014
sh-4.1$ 

Re: Is daylight saving time screwing up availabity report ?

Posted: Thu Apr 03, 2014 4:48 pm
by sreinhardt
Since we are in CDT as well, location not time of year :), I'm going to do some reports and see if I can replicate what you mean.

Re: Is daylight saving time screwing up availabity report ?

Posted: Thu Apr 03, 2014 5:05 pm
by mmazerolle
I'll post the time period I am using when I get to the office tomorrow morning

Re: Is daylight saving time screwing up availabity report ?

Posted: Fri Apr 04, 2014 12:32 pm
by sreinhardt
Doing some testing on my machines, I am not seeing any issues with core 3, no changes in the change log related to reporting. If you could provide the time period you are using, and what settings for the report you are generating, I will try with those as well.

Re: Is daylight saving time screwing up availabity report ?

Posted: Mon Apr 07, 2014 7:58 am
by mmazerolle
This is the time period definition I am using.

Code: Select all

define timeperiod{
        timeperiod_name CHA_Operation
        alias           CHA Operations hours

        monday          06:00-24:00
        tuesday         00:00-24:00
        wednesday       00:00-24:00
        thursday        00:00-24:00
        friday          00:00-17:00
        }
Then I use the interface to generate the report :

- Availability/Hostgroup/CHA
- Report period : Last month
- Report time period : CHA_Operation

First page looks like this :

Code: Select all

Hostgroup 'CHA' Host State Breakdowns:
Host	% Time Up	% Time Down	% Time Unreachable	% Time Undetermined
CHAPHXAP03	100.215% (99.990%)	0.000% (0.000%)	0.010% (0.010%)	1151482151916950.500%
CHAPHXDB03	100.225% (100.000%)	0.000% (0.000%)	0.000% (0.000%)	1151482151916950.500%
Average	100.220% (99.995%)	0.000% (0.000%)	0.005% (0.005%)	1151482151916950.500%
I am leaving for a week outside the office. I'll be back on the 16th.

Marc

Re: Is daylight saving time screwing up availabity report ?

Posted: Mon Apr 07, 2014 2:51 pm
by sreinhardt
Even with that timeperiod and the same settings as you had, as well as going to the extent of trying many of the other options in varying states, I am unable to generate a similar error. Are you getting this same issue with other time periods, whether for the last week\day or instead of cha_operation using 24x7 or something along those lines?

Re: Is daylight saving time screwing up availabity report ?

Posted: Mon Apr 07, 2014 3:30 pm
by mmazerolle
Here are a few more tests using a combination of hostgroups

- Hostgroup CHA, "Last month" and time period 24x7 : All OK

Code: Select all

Hostgroup 'CHA' Host State Breakdowns:
Host	% Time Up	% Time Down	% Time Unreachable	% Time Undetermined
CHAPHXAP03	99.994% (99.994%)	0.000% (0.000%)	0.006% (0.006%)	0.000%
CHAPHXDB03	100.000% (100.000%)	0.000% (0.000%)	0.000% (0.000%)	0.000%
Average	99.997% (99.997%)	0.000% (0.000%)	0.003% (0.003%)	0.000%
- Hostgroup CHA, "Last 31 days" and time period "CHA_operation" : Same problem

Code: Select all

Hostgroup 'CHA' Host State Breakdowns:
Host	% Time Up	% Time Down	% Time Unreachable	% Time Undetermined
CHAPHXAP03	100.218% (99.990%)	0.000% (0.000%)	0.010% (0.010%)	1167219948981874.500%
CHAPHXDB03	100.228% (100.000%)	0.000% (0.000%)	0.000% (0.000%)	1167219948981874.500%
Average	100.223% (99.995%)	0.000% (0.000%)	0.005% (0.005%)	1167219948981874.500%
- Another hostgroup (AOF), Last month, time period CHA_operation : Same problem

Code: Select all

Hostgroup 'AOF' Host State Breakdowns:
Host	% Time Up	% Time Down	% Time Unreachable	% Time Undetermined
AOFPHXAP03	100.222% (99.998%)	0.000% (0.000%)	0.002% (0.002%)	1151482151916950.500%
AOFPHXDB03	100.225% (100.000%)	0.000% (0.000%)	0.000% (0.000%)	1151482151916950.500%
Average	100.223% (99.999%)	0.000% (0.000%)	0.001% (0.001%)	1151482151916950.500%
- Another hostgroup (AOF), Last month, time period AOF_operation : OK

Code: Select all

Hostgroup 'AOF' Host State Breakdowns:
Host	% Time Up	% Time Down	% Time Unreachable	% Time Undetermined
AOFPHXAP03	99.998% (99.998%)	0.000% (0.000%)	0.002% (0.002%)	0.000%
AOFPHXDB03	100.000% (100.000%)	0.000% (0.000%)	0.000% (0.000%)	0.000%
Average	99.999% (99.999%)	0.000% (0.000%)	0.001% (0.001%)	0.000%
AOF_operation (very similar):

Code: Select all

# Theses defines the customers standard operation hours. Use only for reporting
# purpuses to exclude downtimes while the customer is normally not operating.
define timeperiod{
        timeperiod_name AOF_Operation
        alias           AOF Operations hours

        sunday          12:00-24:00
        monday          00:00-24:00
        tuesday         00:00-24:00
        wednesday       00:00-24:00
        thursday        00:00-24:00
        friday          00:00-24:00
        saturday        00:00-12:30
        }
Ummm. seems to be pointing more and more toward the time period..

Re: Is daylight saving time screwing up availabity report ?

Posted: Mon Apr 07, 2014 3:53 pm
by sreinhardt
Very interesting, do you have any other timeperiods that do not account for every day of the week? That is about the only thing that I can see with the issue prone one, that your other two working TPs do have.