[Xymon] Variables in config files

Scot Kreienkamp Scot.Kreienkamp at la-z-boy.com
Wed May 16 19:53:38 CEST 2018


Hi everyone,

Is there a way to define a line or part of a line as a variable in the config files, then use that variable in other places, other than the .default line?  I know it's possible in alerts, but how about hosts.cfg and hosts.d/*, or analysis.cfg and analysis.d/*?

For example, like this:

$DOWNTIME='DOWNTIME=*:6:2200:2359:Scheduled maintenance,*:0:0000:0400:Scheduled maintenance'


0.0.0.0   test1.lzb.hq # $DOWNTIME

0.0.0.0   test2.lzb.hq # $DOWNTIME



Yes, I realize I could use the .default line, but I can't set that once then have that available everywhere.  If I change it later in the config then it won't be available to the rest of the config yet to come.  For the variables I'd like to be able to set the variable and have it available throughout the entire config.  That way I only have to change it in one place.  Right now I have the .default line duplicated many times in my config, and if I have to make a change to them all it starts to become a lot of work.



Thanks!

Scot Kreienkamp | Senior Systems Engineer | La-Z-Boy Corporate
One La-Z-Boy Drive | Monroe, Michigan 48162  | * 734-384-6403 | | * 7349151444 | *  Scot.Kreienkamp at la-z-boy.com<mailto:%7BE-mail%7D>
www<http://www.la-z-boy.com/>.la-z-boy.com<http://www.la-z-boy.com/> | facebook.<https://www.facebook.com/lazboy>com<https://www.facebook.com/lazboy>/<https://www.facebook.com/lazboy>lazboy<http://facebook.com/lazboy> | twitter.com/lazboy<https://twitter.com/lazboy> | youtube.com/<https://www.youtube.com/user/lazboy>lazboy<https://www.youtube.com/user/lazboy>

[cid:lzbVertical_hres.jpg]



This message is intended only for the individual or entity to which it is addressed.  It may contain privileged, confidential information which is exempt from disclosure under applicable laws.  If you are not the intended recipient, you are strictly prohibited from disseminating or distributing this information (other than to the intended recipient) or copying this information.  If you have received this communication in error, please notify us immediately by e-mail or by telephone at the above number. Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20180516/f7943a07/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lzbVertical_hres.jpg
Type: image/jpeg
Size: 21288 bytes
Desc: lzbVertical_hres.jpg
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20180516/f7943a07/attachment.jpg>


More information about the Xymon mailing list