Custom variables are are case-sensitive. Try using NAGIOS__HOSTserverfunction.
Alex Griffin --- Tech Team agrif...@nagios.com On 06/16/2012 06:05 AM, Ruslan Valiyev wrote: > Hi all, > > We have custom variables like this: > > define host { > use linux-server > host_name host.foo.com <http://host.foo.com> > address 192.168.1.44 > _serverfunction Oracle EBS R12 Application Server > _serveradmin Admins_Linux > _serviceadmin //Admins_Oracle > _userorg ACME > } > > Now we have our own script to send out the notifications. And, > apparently, custom variables are not exported outside Nagios for safety. > > To give an example of when we’re able to get the var data: > my $o_hostname = $ENV{NAGIOS_HOSTNAME}; > > And this one doesn’t return anything: > my $o_hostfunction = $ENV{NAGIOS__HOSTSERVERFUNCTION}; > > Could someone help finding this limitation in the source code? The > environment we have is pretty strict and isolated, also the custom > variables we use never contain any confidential information. > > > Regards, > Ruslan > > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > > > > _______________________________________________ > Nagios-users mailing list > Nagios-users@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 ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Nagios-users mailing list Nagios-users@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