Xymon Mailing List Archive search

no service-alert for all hosts

8 messages in this thread

list Martin Flemming · Thu, 12 Mar 2009 22:54:01 +0100 (CET) ·
Hi !

I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?

thanks & cheers,

        Martin
list Malcolm Hunter · Thu, 12 Mar 2009 23:09:08 +0100 ·
quoted from Martin Flemming
I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?
I would have thought the syntax would be:
HOST=* SERVICE=test1,test2,test3
   IGNORE


It's worth watching your /var/log/maillog for any anomalies after making a change.

Regards,
Malcolm

-- 
Technical copy-editor & proofreader

KDE Proofreading Team
KDE British English Translation Team

http://l10n.kde.org/team-infos.php?teamcode=en_GB

Nur bis 16.03.! DSL-Komplettanschluss inkl. WLAN-Modem für nur 
17,95 ¿/mtl. + 1 Monat gratis!* http://dsl.gmx.de/?ac=OM.AD.PD003K11308T4569a
list Steinar M. Skúlason · Thu, 12 Mar 2009 22:16:40 +0000 ·
Do you want to ignore these permanently
Or randomly ?
Or based on what day it is ?

Of course permanently is easy

HOST=sfdsf
quoted from Martin Flemming


On Thu, Mar 12, 2009 at 9:54 PM, Martin Flemming <user-f286aaa49a76@xymon.invalid>wrote:
Hi !

I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?

thanks & cheers,

      Martin

list Martin Flemming · Thu, 12 Mar 2009 23:17:45 +0100 (CET) ·
Yep !

Great, thanks a lot ..

cheers,
 	martin
quoted from Malcolm Hunter

On Thu, 12 Mar 2009, Malcolm Hunter wrote:
I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?
I would have thought the syntax would be:
HOST=* SERVICE=test1,test2,test3
  IGNORE


It's worth watching your /var/log/maillog for any anomalies after making a change.

Regards,
Malcolm

-- 
Technical copy-editor & proofreader

KDE Proofreading Team
KDE British English Translation Team

http://l10n.kde.org/team-infos.php?teamcode=en_GB

Nur bis 16.03.! DSL-Komplettanschluss inkl. WLAN-Modem für nur
17,95 ¿/mtl. + 1 Monat gratis!* http://dsl.gmx.de/?ac=OM.AD.PD003K11308T4569a

Gruss

        Martin Flemming


Martin Flemming
DESY / IT          office : Building 2b / 008a
Notkestr. 85       phone  : XXX - XXXX - XXXX
22603 Hamburg      mail   : user-f286aaa49a76@xymon.invalid
list Martin Flemming · Thu, 12 Mar 2009 23:24:59 +0100 (CET) ·
In this moment i need it permanently .. ;-)

but if you can give me some examples for
Or randomly ?
Or based on what day it is ?
.. i will not angry ;-)

thanks
quoted from Martin Flemming
 	martin

On Thu, 12 Mar 2009, Steinar M. Skúlason wrote:
Do you want to ignore these permanently
Or randomly ?
Or based on what day it is ?

Of course permanently is easy

HOST=sfdsf


On Thu, Mar 12, 2009 at 9:54 PM, Martin Flemming <user-f286aaa49a76@xymon.invalid>wrote:
Hi !

I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?

thanks & cheers,

      Martin

Gruss

        Martin Flemming


Martin Flemming
DESY / IT          office : Building 2b / 008a
Notkestr. 85       phone  : XXX - XXXX - XXXX
22603 Hamburg      mail   : user-f286aaa49a76@xymon.invalid
list Steinar M. Skúlason · Thu, 12 Mar 2009 22:35:48 +0000 ·
oops, accidentally sent that one, damn touch pad :)

what I meant to finish is you only mention which services you would like to
receive alerts for

HOST=hostname
   MAIL user-433de7fe0fec@xymon.invalid RECOVERED REPEAT=60 COLOR=red SERVICE=http


If it's based on time of day or some other criteria, then I think that
hobbit-alerts.cfg resolves environment variales
Or just create a small sed script to change lines in hobbit-alerts.cfg ..
like :

#!/bin/bash
file="/usr/lib/hobbit/server/etc/hobbit-alerts.cfg"
OLDTEXT="SERVICE=.*$"
NEWTEXT="http,ssh"
if [ -f $file ]; then
   sed "s/^$OLDTEXT/$NEWTEXT/g" < $file >/tmp/$$ && mv /tmp/$$ $file
fi

This replaces everything from SERVICE to end of line with what you put in
NEWTEXT for all lines in the file

This will only change the first occurrence
sed "s/^$OLDTEXT/$NEWTEXT/" < $file >/tmp/$$ && mv /tmp/$$ $file

an easier sed search and relplace can also be just
sed  -e 's/*oldtext*/newtext/' <filename>


Hope this helps,
wasn't quite sure what you ment

On Thu, Mar 12, 2009 at 10:16 PM, Steinar M. Skúlason
quoted from Martin Flemming
<user-3b78224d184c@xymon.invalid>wrote:
Do you want to ignore these permanently
Or randomly ?
Or based on what day it is ?

Of course permanently is easy

HOST=sfdsf


On Thu, Mar 12, 2009 at 9:54 PM, Martin Flemming <user-f286aaa49a76@xymon.invalid>wrote:
Hi !

I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?

thanks & cheers,

      Martin

list Steinar M. Skúlason · Thu, 12 Mar 2009 22:41:05 +0000 ·
based on the day I would use crontab

but I obviously didn't get the questions because I didn't even recognize the
IGNORE switch

always trying to create the wheel instead of reading the docs I guess :)


-Steinar

On Thu, Mar 12, 2009 at 10:35 PM, Steinar M. Skúlason
quoted from Steinar M. Skúlason
<user-3b78224d184c@xymon.invalid>wrote:
oops, accidentally sent that one, damn touch pad :)

what I meant to finish is you only mention which services you would like to
receive alerts for

HOST=hostname
   MAIL user-433de7fe0fec@xymon.invalid RECOVERED REPEAT=60 COLOR=red SERVICE=http


If it's based on time of day or some other criteria, then I think that
hobbit-alerts.cfg resolves environment variales
Or just create a small sed script to change lines in hobbit-alerts.cfg ..
like :

#!/bin/bash
file="/usr/lib/hobbit/server/etc/hobbit-alerts.cfg"
OLDTEXT="SERVICE=.*$"
NEWTEXT="http,ssh"
if [ -f $file ]; then
   sed "s/^$OLDTEXT/$NEWTEXT/g" < $file >/tmp/$$ && mv /tmp/$$ $file
fi

This replaces everything from SERVICE to end of line with what you put in
NEWTEXT for all lines in the file

This will only change the first occurrence
sed "s/^$OLDTEXT/$NEWTEXT/" < $file >/tmp/$$ && mv /tmp/$$ $file

an easier sed search and relplace can also be just
sed  -e 's/*oldtext*/newtext/' <filename>


Hope this helps,
wasn't quite sure what you ment


On Thu, Mar 12, 2009 at 10:16 PM, Steinar M. Skúlason <user-3b78224d184c@xymon.invalid
quoted from Steinar M. Skúlason
wrote:
Do you want to ignore these permanently
Or randomly ?
Or based on what day it is ?

Of course permanently is easy

HOST=sfdsf


On Thu, Mar 12, 2009 at 9:54 PM, Martin Flemming <user-f286aaa49a76@xymon.invalid
quoted from Steinar M. Skúlason
wrote:
Hi !

I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?

thanks & cheers,

      Martin

list Martin Flemming · Thu, 12 Mar 2009 23:56:33 +0100 (CET) ·
.. it was me one honours :-)

thanks a lot !
quoted from Steinar M. Skúlason

 		martin

On Thu, 12 Mar 2009, Steinar M. Skúlason wrote:
based on the day I would use crontab

but I obviously didn't get the questions because I didn't even recognize the
IGNORE switch

always trying to create the wheel instead of reading the docs I guess :)


-Steinar

On Thu, Mar 12, 2009 at 10:35 PM, Steinar M. Skúlason
<user-3b78224d184c@xymon.invalid>wrote:
oops, accidentally sent that one, damn touch pad :)

what I meant to finish is you only mention which services you would like to
receive alerts for

HOST=hostname
   MAIL user-433de7fe0fec@xymon.invalid RECOVERED REPEAT=60 COLOR=red SERVICE=http


If it's based on time of day or some other criteria, then I think that
hobbit-alerts.cfg resolves environment variales
Or just create a small sed script to change lines in hobbit-alerts.cfg ..
like :

#!/bin/bash
file="/usr/lib/hobbit/server/etc/hobbit-alerts.cfg"
OLDTEXT="SERVICE=.*$"
NEWTEXT="http,ssh"
if [ -f $file ]; then
   sed "s/^$OLDTEXT/$NEWTEXT/g" < $file >/tmp/$$ && mv /tmp/$$ $file
fi

This replaces everything from SERVICE to end of line with what you put in
NEWTEXT for all lines in the file

This will only change the first occurrence
sed "s/^$OLDTEXT/$NEWTEXT/" < $file >/tmp/$$ && mv /tmp/$$ $file

an easier sed search and relplace can also be just
sed  -e 's/*oldtext*/newtext/' <filename>


Hope this helps,
wasn't quite sure what you ment


On Thu, Mar 12, 2009 at 10:16 PM, Steinar M. Skúlason <user-3b78224d184c@xymon.invalid
wrote:
Do you want to ignore these permanently
Or randomly ?
Or based on what day it is ?

Of course permanently is easy

HOST=sfdsf


On Thu, Mar 12, 2009 at 9:54 PM, Martin Flemming <user-f286aaa49a76@xymon.invalid
wrote:
Hi !

I've got in my hobbit-alerts.cfg
many HOST and PAGE/SUBPAGE rules ...

Now i need (at the top i think)
one rule, which disable alerting of some Services
for all hosts ..

My first attempt is at the top

IGNORE SERVICE=test1,test2,test3

.. i thought, that's it .. but now, my mailmaster
is angry because many mails hanging around in the  mail-queue

with user-e9f892b96bdd@xymon.invalid ....

Any hint ?

thanks & cheers,

      Martin