(no subject)

jeff vier jeff.vier at tradingtechnologies.com
Fri Nov 21 19:32:54 CET 2003


On Fri, 2003-11-21 at 11:30, Parmar, Satbir wrote:
> Can someone tell me how to set up in our e-mail notification with the
> Environment name included. We currently use names for our servers e.g
> Animal names but they belong to a group, how can I get the group name
> onto the e-mail as well.

You can hack it to extrapolate the hostgroup_name from your
~nagios/etc/hostgroups.cfg file, but this can't really be default (like
$HOSTGROUP$ or something) because a host can belong to multiple groups.

At least, that's my theory :)

try something like
`grep $HOSTNAME$ ~nagios/etc/hostgroups.cfg -A3 -B3 | grep
hostgroup_name | awk '{print $2}'`

good luck.



-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?  SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list