resource.cfg variables in services as arguments

Jan Scholten Jan.Scholten at iconz.net
Wed Nov 10 22:18:27 CET 2004


I don't know if nagios expands the Arguments in the check_command line.

I use $USER3$ in the checkcommands for the read community.

So i don't pass resources Variables in Service statements (since most of 
our read community is the same, if not i would define a new checkcommand.

Jan
> Hello.  I would like to be able to have several community strings for 
> the same check_command, without exposing them in my service 
> configuration files.  I would really like to be able to say
> 
>   check_command                   my_snmp_check!$USER1$
> 
> in a "service" statement.  I believe "$USER1$" is treated as a literal 
> in this context.
> 
> When I replace $ARG1$ with $USER1$ in the check itself, or $USER1$ in 
> the service with the actual community string, then the SNMP query finds 
> the community string and works fine.
> 
> Am I doing anything wrong?  Is the above (treating "$USER1$" as a 
> literal) the intended action?  Do people just not pass resource strings 
> inside service statements?
> 
> Thank you very much.
> 
> Yours,
> John



-------------------------------------------------------
This SF.Net email is sponsored by:
Sybase ASE Linux Express Edition - download now for FREE
LinuxWorld Reader's Choice Award Winner for best database on Linux.
http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click
_______________________________________________
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