How do you define days with "TIME" in the hobbit-alerts.cfg?
list James Gearing
Hi all, I'm trying to setup my pager to alert me Monday - Friday, 7:00 - 24:00. I understand how to set the hours, but how do you set the days? All the examples I have seen with days in them, only list one day or *. To do multiple days, do you use "," between the days? Can you use a range character? I have also seen Wednesday listed as W or 3 in the examples, will either work? TIME=1,2,3,4,5:700:2400 <---is that right? Thanks, James
list Larry Barber
"W" means week days, not just Wednesday so you could just use that. Otherwise to specify weekdays you could say 12345:... (note no commas). Thanks, Larry Barber
▸
On 7/25/06, Gearing, James <user-eb1a3271f7cc@xymon.invalid> wrote:Hi all, I'm trying to setup my pager to alert me Monday - Friday, 7:00 - 24:00. I understand how to set the hours, but how do you set the days? All the examples I have seen with days in them, only list one day or *. To do multiple days, do you use "," between the days? Can you use a range character? I have also seen Wednesday listed as W or 3 in the examples, will either work? TIME=1,2,3,4,5:700:2400 <---is that right? Thanks, James
list R. Leyton
Hi James, You probably want to look at the bb-hosts(5) man page (specifically the NKTIME section).
day-of-week: W means Mon-Fri ("weekdays"), * means all days, 0
.. 6 = Sunday .. Saturday. Listing multiple days is possible,
e.g. "60" is valid meaning "Saturday and Sunday".ie. you're probably after a specification such as: TIME=W:0700:0000 Hope that helps, regards, Richard -- Richard Leyton - user-787ca786c598@xymon.invalid http://www.leyton.org
▸
On 25 Jul 2006, at 19:51, Gearing, James wrote:
Hi all, I'm trying to setup my pager to alert me Monday - Friday, 7:00 - 24:00. I understand how to set the hours, but how do you set the days? All the examples I have seen with days in them, only list one day or *. To do multiple days, do you use "," between the days? Can you use a range character? I have also seen Wednesday listed as W or 3 in the examples, will either work? TIME=1,2,3,4,5:700:2400 <---is that right? Thanks, James
list James Gearing
Thanks, that's what I was looking for. Another question. Is it possible to do multiple TIME statements in one alert? I'd like to get the alert 7-12 m-f and all day sat and sun. Know if that's possible? -----Original Message----- From: R. Leyton [mailto:user-787ca786c598@xymon.invalid] Sent: Tuesday, July 25, 2006 3:01 PM To: user-ae9b8668bcde@xymon.invalid Subject: Re: [hobbit] How do you define days with "TIME" in the hobbit-alerts.cfg?
▸
Hi James,
You probably want to look at the bb-hosts(5) man page (specifically the
NKTIME section).
day-of-week: W means Mon-Fri ("weekdays"), * means all days, 0
.. 6 = Sunday .. Saturday. Listing multiple days is possible,
e.g. "60" is valid meaning "Saturday and Sunday".ie. you're probably after a specification such as: TIME=W:0700:0000 Hope that helps, regards, Richard -- Richard Leyton - user-787ca786c598@xymon.invalid http://www.leyton.org On 25 Jul 2006, at 19:51, Gearing, James wrote:
Hi all, I'm trying to setup my pager to alert me Monday - Friday, 7:00 - 24:00. I understand how to set the hours, but how do you set the days? All the examples I have seen with days in them, only list one day or *. To
do multiple days, do you use "," between the days? Can you use a range
character? I have also seen Wednesday listed as W or 3 in the examples, will either work? TIME=1,2,3,4,5:700:2400 <---is that right? Thanks, James
list R. Leyton
Per a paragraph or two below what I quoted, there's this, which answers your question:
If necessary, multiple periods can be specified. E.g. to monitor
a site 24x7, except between noon and 1 pm, use
NKTIME=*:0000:1159,*:1300:2359
The interval between starttime and endtime may cross midnight,
e.g. *:2330:0200 would be valid and have the same effect as
*:2330:2400,*:0000:0200.So, probably: TIME=W:0700:2400,06:0000:2400 It might be a nice tweak to have 'E' for weekend, or something along those lines, in a future release. r.
▸
On 25 Jul 2006, at 20:06, Gearing, James wrote:
Thanks, that's what I was looking for. Another question. Is it possible to do multiple TIME statements in one alert? I'd like to get the alert 7-12 m-f and all day sat and sun. Know if that's possible? -----Original Message----- From: R. Leyton [mailto:user-787ca786c598@xymon.invalid] Sent: Tuesday, July 25, 2006 3:01 PM To: user-ae9b8668bcde@xymon.invalid Subject: Re: [hobbit] How do you define days with "TIME" in the hobbit-alerts.cfg? Hi James, You probably want to look at the bb-hosts(5) man page (specifically the NKTIME section).day-of-week: W means Mon-Fri ("weekdays"), * means all days, 0 .. 6 = Sunday .. Saturday. Listing multiple days is possible, e.g. "60" is valid meaning "Saturday and Sunday".ie. you're probably after a specification such as: TIME=W:0700:0000 Hope that helps, regards, Richard -- Richard Leyton - user-787ca786c598@xymon.invalid http://www.leyton.org On 25 Jul 2006, at 19:51, Gearing, James wrote:Hi all, I'm trying to setup my pager to alert me Monday - Friday, 7:00 - 24:00. I understand how to set the hours, but how do you set the days? All the examples I have seen with days in them, only list one day or *. Todo multiple days, do you use "," between the days? Can you use a rangecharacter? I have also seen Wednesday listed as W or 3 in the examples, will either work? TIME=1,2,3,4,5:700:2400 <---is that right? Thanks, James