List of Variables passed to Scripts
list Geoff Hallford
Hi, Is there a list of the variables that are passed to alerting scripts and what they contain? I haven't found a list and I would like to make our custom alerting script much more descriptive by adding items such as IP address, ... Thanks.
list Geoff Hallford
Actually I found the IP but I know there are others that aren't currently documented. Thanks.
▸
On 3/19/07, Geoff Hallford <user-dc9e7f30b1e2@xymon.invalid> wrote:Hi, Is there a list of the variables that are passed to alerting scripts and what they contain? I haven't found a list and I would like to make our custom alerting script much more descriptive by adding items such as IP address, ... Thanks.
--
'If my answers frighten you then you should cease asking scary questions.'
--Sam Jackson
list Tom Kauffman
Check the man pages for hobbit-alerts.cfg; at the end is the list of environment variables passed to the scripts. Tom
▸
From: Geoff Hallford [mailto:user-dc9e7f30b1e2@xymon.invalid] Sent: Monday, March 19, 2007 1:01 PM
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] List of Variables passed to Scripts
Hi,
Is there a list of the variables that are passed to alerting scripts and
what they contain? I haven't found a list and I would like to make our
custom alerting script much more descriptive by adding items such as IP
address, ...
Thanks.
CONFIDENTIALITY NOTICE: This email and any attachments are for the exclusive and confidential use of the intended recipient. If you are not
the intended recipient, please do not read, distribute or take action in reliance upon this message. If you have received this in error, please notify us immediately by return email and promptly delete this message and its attachments from your computer system. We do not waive attorney-client or work product privilege by the transmission of this
message.
list Geoff Hallford
Hi Tom, Thanks I know about this list but it doesn't provide all variables passed to the scripts. When I wanted to find out a couple months ago, how to include the DESCR tag (from bb-hosts) in my script, Henrik told me I could use the $BBH_DESCRIPTION variable and it does work and is passed to the script. This variable is not included in the list in hobbit-alerts.cfg man page. I am just wondering if there are more variables not listed in there, that are passed because I have alerts for 8 organizations on my server and about 700 servers/devices, so I would like to be more descriptive if possible in my alerting. Thanks for the thought though.
▸
On 3/19/07, Kauffman, Tom <user-3feba9e60a8b@xymon.invalid> wrote:Check the man pages for hobbit-alerts.cfg; at the end is the list of environment variables passed to the scripts. Tom *From:* Geoff Hallford [mailto:user-dc9e7f30b1e2@xymon.invalid] *Sent:* Monday, March 19, 2007 1:01 PM *To:* user-ae9b8668bcde@xymon.invalid *Subject:* [hobbit] List of Variables passed to Scripts Hi, Is there a list of the variables that are passed to alerting scripts and what they contain? I haven't found a list and I would like to make our custom alerting script much more descriptive by adding items such as IP address, ... Thanks. CONFIDENTIALITY NOTICE: This email and any attachments are for the exclusive and confidential use of the intended recipient. If you are not the intended recipient, please do not read, distribute or take action in reliance upon this message. If you have received this in error, please notify us immediately by return email and promptly delete this message and its attachments from your computer system. We do not waive attorney-client or work product privilege by the transmission of this message.
-- 'If my answers frighten you then you should cease asking scary questions.' --Sam Jackson
list Ralph Mitchell
▸
On 3/19/07, Geoff Hallford <user-dc9e7f30b1e2@xymon.invalid> wrote:
Hi Tom, Thanks I know about this list but it doesn't provide all variables passed to the scripts. When I wanted to find out a couple months ago, how to include the DESCR tag (from bb-hosts) in my script, Henrik told me I could use the $BBH_DESCRIPTION variable and it does work and is passed to the script. This variable is not included in the list in hobbit-alerts.cfg man page. I am just wondering if there are more variables not listed in there, that are passed because I have alerts for 8 organizations on my server and about 700 servers/devices, so I would like to be more descriptive if possible in my alerting.
Did you try putting something like: env > /tmp/alert.env into the alert script?? It should tell you *everything* that gets passed in the environment. Ralph Mitchell
list Geoff Hallford
Forgot about env. That works perfectly to get the info I need. Thanks.
▸
On 3/19/07, Ralph Mitchell <user-00a5e44c48c0@xymon.invalid> wrote:On 3/19/07, Geoff Hallford <user-dc9e7f30b1e2@xymon.invalid> wrote:Hi Tom, Thanks I know about this list but it doesn't provide all variables passed to the scripts. When I wanted to find out a couple months ago, how to include the DESCR tag (from bb-hosts) in my script, Henrik told me I could use the $BBH_DESCRIPTION variable and it does work and is passed to the script.Thisvariable is not included in the list in hobbit-alerts.cfg man page. I am just wondering if there are more variables not listed in there, that are passed because I have alerts for 8 organizations on my server and about700servers/devices, so I would like to be more descriptive if possible in my alerting.Did you try putting something like: env > /tmp/alert.env into the alert script?? It should tell you *everything* that gets passed in the environment. Ralph Mitchell
list Charles Jones
Make a script that performs the "export" command, and logs the output to a file, then you should be able to see all the available variables, including Hobbit ones :) -Charles
▸
Geoff Hallford wrote:Hi Tom,
Thanks I know about this list but it doesn't provide all variables passed to the scripts. When I wanted to find out a couple months ago, how to include the DESCR tag (from bb-hosts) in my script, Henrik told me I could use the $BBH_DESCRIPTION variable and it does work and is passed to the script. This variable is not included in the list in hobbit-alerts.cfg man page. I am just wondering if there are more variables not listed in there, that are passed because I have alerts for 8 organizations on my server and about 700 servers/devices, so I would like to be more descriptive if possible in my alerting.
Thanks for the thought though.
On 3/19/07, *Kauffman, Tom* <user-3feba9e60a8b@xymon.invalid <mailto:user-3feba9e60a8b@xymon.invalid>> wrote:
Check the man pages for hobbit-alerts.cfg; at the end is the list
of environment variables passed to the scripts.
Tom
*From:* Geoff Hallford [mailto: user-dc9e7f30b1e2@xymon.invalid
<mailto:user-dc9e7f30b1e2@xymon.invalid>]
*Sent:* Monday, March 19, 2007 1:01 PM
*To:* user-ae9b8668bcde@xymon.invalid <mailto:user-ae9b8668bcde@xymon.invalid>
▸
*Subject: * [hobbit] List of Variables passed to Scripts
Hi,
Is there a list of the variables that are passed to alerting
scripts and what they contain? I haven't found a list and I would
like to make our custom alerting script much more descriptive by
adding items such as IP address, ...
Thanks.
CONFIDENTIALITY NOTICE: This email and any attachments are for the exclusive and confidential use of the intended recipient. If you are not
the intended recipient, please do not read, distribute or take action in reliance upon this message. If you have received this in error, please notify us immediately by return email and promptly delete this message and its attachments from your computer system. We do not waive attorney-client or work product privilege by the transmission of this
message.
--
'If my answers frighten you then you should cease asking scary questions.' --Sam Jacksonlist Geoff Hallford
Thanks Charles. The 'env' command gave me the same results but a good suggestion none the less.
▸
On 3/20/07, Charles Jones <user-e86b4aeade4e@xymon.invalid> wrote:Make a script that performs the "export" command, and logs the output to a file, then you should be able to see all the available variables, including Hobbit ones :) -Charles Geoff Hallford wrote: Hi Tom, Thanks I know about this list but it doesn't provide all variables passed to the scripts. When I wanted to find out a couple months ago, how to include the DESCR tag (from bb-hosts) in my script, Henrik told me I could use the $BBH_DESCRIPTION variable and it does work and is passed to the script. This variable is not included in the list in hobbit-alerts.cfg man page. I am just wondering if there are more variables not listed in there, that are passed because I have alerts for 8 organizations on my server and about 700 servers/devices, so I would like to be more descriptive if possible in my alerting. Thanks for the thought though. On 3/19/07, Kauffman, Tom <user-3feba9e60a8b@xymon.invalid> wrote:Check the man pages for hobbit-alerts.cfg; at the end is the list of environment variables passed to the scripts. Tom *From:* Geoff Hallford [mailto: user-dc9e7f30b1e2@xymon.invalid] *Sent:* Monday, March 19, 2007 1:01 PM *To:* user-ae9b8668bcde@xymon.invalid *Subject: *[hobbit] List of Variables passed to Scripts Hi, Is there a list of the variables that are passed to alerting scripts and what they contain? I haven't found a list and I would like to make our custom alerting script much more descriptive by adding items such as IP address, ... Thanks. CONFIDENTIALITY NOTICE: This email and any attachments are for the exclusive and confidential use of the intended recipient. If you are not the intended recipient, please do not read, distribute or take action in reliance upon this message. If you have received this in error, please notify us immediately by return email and promptly delete this message and its attachments from your computer system. We do not waive attorney-client or work product privilege by the transmission of this message.-- 'If my answers frighten you then you should cease asking scary questions.' --Sam Jackson
-- 'If my answers frighten you then you should cease asking scary questions.' --Sam Jackson