a "$" in checkcommands definition
Scott Barnhill
scottb at ssbweb.com
Wed Nov 12 01:53:37 CET 2003
All,
I'm trying to set up a check to check the number of items in an MSMQ
Queue on a windows server. I'm using NSClient to get to a Counter that
provides the number of items in the queue. From the command line the
check_nt command executes as expected. However when executed from within
Nagios it returns: Return code of 127 is out of bounds.)
The nagios configs are as follows:
define command{
host_name wf1
service_description AUDIT Q MSG
is_volatile 0
check_period 24x7
max_check_attempts 3
normal_check_interval 3
retry_check_interval 1
contact_groups techops
notification_interval 120
notification_period 24x7
notification_options u
check_command audit_queue!5!10
}
and:
# Check the number of items in the MSMQ Audit Queue
define command{
command_name audit_queue
command_line $USER$/check_nt -H $HOSTADDRESS$ -p 1248 -v
COUNTER -l '\\MSMQ Queue(wf1\private$\ppmd audit)\\Messages in
Queue','Items in MSMQ Audit Queue: %.f' -w $ARG1$ -c $ARG2$
}
I'm pretty sure that it's the fact that the MSMQ queue name in the -l
portion of the command has a "$" contained in it. Is there any way to
escape out the "$" ? I've tried single, double quotes, and "\" before
it. I've also tried putting the "private$" portion into $ARG1$. All with
no success. Does anybody have any additional ideas?
Thanks!
-scott
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20031111/1cb44c6c/attachment.html>
More information about the Users
mailing list