Page 1 of 1

Macros in Email template

Posted: Fri Feb 20, 2015 8:47 am
by MSPk
Hi Team,

I'm trying to put in a macro in our email template to get the information of the service groups the monitored service is part off, I have added the macro $SERVICEGROUPNAMES$ to my email (in different formats like - $SERVICEGROUPNAMES$, %SERVICEGROUPNAMES%,%servicegroupnames%) but when the notification is sent out we don't see the relevant information instead we have the macro in the email as shown below. Did I use a wrong macro? I referring the link - http://nagios.sourceforge.net/docs/3_0/ ... groupnames for predefined macros. Please assist.

Service Groups: %SERVICEGROUPNAMES%
%servicegroupnames%

Re: Macros in Email template

Posted: Fri Feb 20, 2015 8:57 am
by scottwilkerson
You will need to add them to the following commands:
xi_service_notification_handler

Code: Select all

--servicegroupnames="$SERVICEGROUPNAMES$"
then you can reference them like %servicegroupnames%

Here is a list of pre-configured macros, and some instructions on adding additional macros
http://assets.nagios.com/downloads/nagi ... iables.pdf

Re: Macros in Email template

Posted: Thu May 07, 2015 9:20 am
by MSPk
Please close this thread as solved