In regards to this old topic: http://support.nagios.com/forum/viewtop ... 16&t=31152
I have a quick question, what is the correct variable to get host group name into the PHP?
One of our coders is going to take a stab at getting it to work.
Thanks.
Passing Host Group via XI SNMP Trap Sender
-
JakeHatMacys
- Posts: 281
- Joined: Thu Sep 25, 2014 3:21 pm
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Passing Host Group via XI SNMP Trap Sender
You would need to modify in the CCM the command
and you can add something like the following to the end of the command
this would add the hostgroupnames to the event_meta array, and it could be accessed with %hostgroupnames% in the command.
You can do the same with any of the macros that are available to even handlers
http://nagios.sourceforge.net/docs/nagi ... olist.html
For services you would need to make similar changes to the following command
Code: Select all
xi_host_event_handlerCode: Select all
--hostgroupnames=$HOSTGROUPNAMES$You can do the same with any of the macros that are available to even handlers
http://nagios.sourceforge.net/docs/nagi ... olist.html
For services you would need to make similar changes to the following command
Code: Select all
xi_service_event_handler