Xymon Mailing List Archive search

DOWNTIME ALERTS

6 messages in this thread

list Tim McCloskey · Thu, 05 Jun 2008 08:50:07 -0700 ·
Hello,

First thank you for the fantastic tool which I have been using for quite
some time now.

I tried using DOWNTIME in bb-hosts instead of using TIME in
hobbit-alerts to ignore alerting on some nightly reboots and inform
operators via the info page what is going on.

DOWNTIME really appears to be a better approach, if I could make it work .

Though I've read some of the posts and documentation I think my
configuration (below) is perhaps wrong as alerts are sent during the
downtime window. Do I need to specify a service, or am I simply
misunderstanding the concept?

Details below.

bb-hosts:
ipaddr someserver # DOWNTIME=*:2200:0730:"Nightly Reboot"


hobbit-alerts.cfg:
HOST=* SERVICE=conn
SCRIPT page-primary.sh FORMAT=sms
REPEAT=30 RECOVERED
SCRIPT page-secondary.sh DURATION>60
FORMAT=sms REPEAT=60
## also have the following to just spew email on everything.
HOST=*
SCRIPT mail-primary.sh FORMAT=sms
COLOR=red DURATION>6 REPEAT=60
SCRIPT mail-secondary.sh FORMAT=sms
COLOR=red DURATION>60 REPEAT=60


page-primary.sh:
/bin/mail -s "$BBSVCNAME $BBHOSTNAME $MACHIP"
user-9ff8dcb42d75@xymon.invalid < /dev/null


notifications.log:
Wed Jun 4 23:04:54 2008 someserver.conn (ipaddr) FORMAT=sms 1212645894 500
Wed Jun 4 23:04:54 2008 someserver.conn (ipaddr) DURATION>60 1212645894 500
Wed Jun 4 23:06:16 2008 someserver.conn (ipaddr) FORMAT=sms 1212645976
500 82


 From "info" page:
Planned downtime: All days:2200:0730:Nightly Reboot
Network tests use: Hostname
Checked with ping: Yes


Thanks and Regards,
list David Stuffle · Thu, 5 Jun 2008 12:48:52 -0400 ·
Try it like this:

ipaddr someserver # "DOWNTIME=*:2200:0730:Nightly Reboot"

Quoting the entire DOWNTIME tag is needed when specifying a reason. (at
least it works for me)


D. Stuffle
quoted from Tim McCloskey
 

-----Original Message-----
From: Tim McCloskey [mailto:user-2644b182ab49@xymon.invalid] 
Sent: Thursday, June 05, 2008 11:50 AM
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] DOWNTIME ALERTS

Hello,

First thank you for the fantastic tool which I have been using for quite
some time now.

I tried using DOWNTIME in bb-hosts instead of using TIME in
hobbit-alerts to ignore alerting on some nightly reboots and inform
operators via the info page what is going on.

DOWNTIME really appears to be a better approach, if I could make it work
.

Though I've read some of the posts and documentation I think my
configuration (below) is perhaps wrong as alerts are sent during the
downtime window. Do I need to specify a service, or am I simply
misunderstanding the concept?

Details below.

bb-hosts:
ipaddr someserver # DOWNTIME=*:2200:0730:"Nightly Reboot"


hobbit-alerts.cfg:
HOST=* SERVICE=conn
SCRIPT page-primary.sh FORMAT=sms
REPEAT=30 RECOVERED
SCRIPT page-secondary.sh DURATION>60
FORMAT=sms REPEAT=60
## also have the following to just spew email on everything.
HOST=*
SCRIPT mail-primary.sh FORMAT=sms
COLOR=red DURATION>6 REPEAT=60
SCRIPT mail-secondary.sh FORMAT=sms
COLOR=red DURATION>60 REPEAT=60


page-primary.sh:
/bin/mail -s "$BBSVCNAME $BBHOSTNAME $MACHIP"
user-9ff8dcb42d75@xymon.invalid < /dev/null


notifications.log:
Wed Jun 4 23:04:54 2008 someserver.conn (ipaddr) FORMAT=sms 1212645894
500 Wed Jun 4 23:04:54 2008 someserver.conn (ipaddr) DURATION>60
1212645894 500 Wed Jun 4 23:06:16 2008 someserver.conn (ipaddr)
FORMAT=sms 1212645976 500 82


 From "info" page:
Planned downtime: All days:2200:0730:Nightly Reboot Network tests use:
Hostname Checked with ping: Yes


Thanks and Regards,
list Tim McCloskey · Thu, 05 Jun 2008 10:27:35 -0700 ·
Thanks, tried that on one host entry but got the same results, however it seems to make sense to quote the whole field.

I've just noticed some odd events in the hobbitd.log that seem point to improper quoting.
2008-06-05 10:17:28 Bad timespec (missing colon or wrong weekdays): 1800:0730:Nightly Reboot
Where bb-hosts contains DOWNTIME=*:1800:0730:"Nightly Reboot"
Yet it does not report this for the entry I cited below:
ipaddr someserver # DOWNTIME=*:2200:0730:"Nightly Reboot"

I am going to change _all_ of the DOWNTIME entries to quote the whole string and see what happens.

Thanks again.

Tim
quoted from David Stuffle


Stuffle, David (Corporate) wrote:
Try it like this:

ipaddr someserver # "DOWNTIME=*:2200:0730:Nightly Reboot"

Quoting the entire DOWNTIME tag is needed when specifying a reason. (at
least it works for me)


D. Stuffle
 
-----Original Message-----
From: Tim McCloskey [mailto:user-2644b182ab49@xymon.invalid] Sent: Thursday, June 05, 2008 11:50 AM
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] DOWNTIME ALERTS

Hello,

First thank you for the fantastic tool which I have been using for quite
some time now.

I tried using DOWNTIME in bb-hosts instead of using TIME in
hobbit-alerts to ignore alerting on some nightly reboots and inform
operators via the info page what is going on.

DOWNTIME really appears to be a better approach, if I could make it work
.

Though I've read some of the posts and documentation I think my
configuration (below) is perhaps wrong as alerts are sent during the
downtime window. Do I need to specify a service, or am I simply
misunderstanding the concept?

Details below.

bb-hosts:
ipaddr someserver # DOWNTIME=*:2200:0730:"Nightly Reboot"


hobbit-alerts.cfg:
HOST=* SERVICE=conn
SCRIPT page-primary.sh FORMAT=sms
REPEAT=30 RECOVERED
SCRIPT page-secondary.sh DURATION>60
FORMAT=sms REPEAT=60
## also have the following to just spew email on everything.
HOST=*
SCRIPT mail-primary.sh FORMAT=sms
COLOR=red DURATION>6 REPEAT=60
SCRIPT mail-secondary.sh FORMAT=sms
COLOR=red DURATION>60 REPEAT=60


page-primary.sh:
/bin/mail -s "$BBSVCNAME $BBHOSTNAME $MACHIP"
user-9ff8dcb42d75@xymon.invalid < /dev/null


notifications.log:
Wed Jun 4 23:04:54 2008 someserver.conn (ipaddr) FORMAT=sms 1212645894
500 Wed Jun 4 23:04:54 2008 someserver.conn (ipaddr) DURATION>60
1212645894 500 Wed Jun 4 23:06:16 2008 someserver.conn (ipaddr)
FORMAT=sms 1212645976 500 82


 From "info" page:
Planned downtime: All days:2200:0730:Nightly Reboot Network tests use:
Hostname Checked with ping: Yes


Thanks and Regards,

list Tim McCloskey · Thu, 05 Jun 2008 10:57:23 -0700 ·
Well that did not help :) And there are still errors in hobbitd.log

2008-06-05 10:52:42 Bad timespec (missing colon or wrong weekdays): 1800:0730:Nightly Reboot

I'll have another look at the man pages :)

Regards,
Tim
signature

I am going to change _all_ of the DOWNTIME entries to quote the whole 
string and see what happens.

Thanks again.

Tim


quoted from Tim McCloskey
Stuffle, David (Corporate) wrote:
Try it like this:

ipaddr someserver # "DOWNTIME=*:2200:0730:Nightly Reboot"

Quoting the entire DOWNTIME tag is needed when specifying a reason. (at
least it works for me)
list Tim McCloskey · Thu, 05 Jun 2008 11:29:34 -0700 ·
Using the syntax I found in the maillist archive appears to have fixed this for me.  Should have tried that prior to 
posting, sorry about that.

Now in bb-hosts:
"DOWNTIME=*:*:1000:1200:"Tim Testing"

Even works with the typo (extra quote).

The rule did not alert the page went blue but the info page only contained:
Planned downtime:	All days:*:1000:1200:
Fixing the typo fixed the info page and everything else worked as expected.

The key point is the additional *: in the line.
"DOWNTIME=*:*:1000:1200:foo moo" works
"DOWNTIME=*:2200:0730:foo moo"   does not work


Thanks and Regards,
Tim
quoted from Tim McCloskey


Tim McCloskey wrote:
Well that did not help :) And there are still errors in hobbitd.log

2008-06-05 10:52:42 Bad timespec (missing colon or wrong weekdays): 
1800:0730:Nightly Reboot

I'll have another look at the man pages :)

Regards,
Tim

list Darin D [eit] Dugan · Fri, 6 Jun 2008 08:54:13 -0500 ·
That agrees with my experience. When specifying the optional reason you
must also specify the optional service.
http://hswn.dk/hobbiton/2008/05/msg00020.html

Cheers.
quoted from Tim McCloskey

-----Original Message-----
From: Tim McCloskey [mailto:user-2644b182ab49@xymon.invalid] 
Sent: Thursday, June 05, 2008 1:30 PM
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] DOWNTIME ALERTS

Using the syntax I found in the maillist archive appears to have fixed
this for me.  Should have tried that prior to 
posting, sorry about that.

Now in bb-hosts:
"DOWNTIME=*:*:1000:1200:"Tim Testing"

Even works with the typo (extra quote).

The rule did not alert the page went blue but the info page only
contained:
Planned downtime:	All days:*:1000:1200:
Fixing the typo fixed the info page and everything else worked as
expected.

The key point is the additional *: in the line.
"DOWNTIME=*:*:1000:1200:foo moo" works
"DOWNTIME=*:2200:0730:foo moo"   does not work


Thanks and Regards,
Tim


Tim McCloskey wrote:
Well that did not help :) And there are still errors in hobbitd.log

2008-06-05 10:52:42 Bad timespec (missing colon or wrong weekdays): 
1800:0730:Nightly Reboot

I'll have another look at the man pages :)

Regards,
Tim