[Nagiosplug-help] check_nrpe idea

Andreas Ericsson ae at op5.se
Fri Apr 30 04:37:31 CEST 2004


Arnold Cano wrote:
> On Wed, 2004-04-28 at 16:04, Cook, Garry wrote:
> 
>>>The problem I find is when check_nrpe tries to forward the
>>>request with
>>>-a arguments that contain spaces like so...
>>>
>>>services.cfg
>>>define service {
>>>  ...
>>>  check_command
>>>indirect_check_nrpe!<ip_of_first_machine>!check_nrpe!service_nrpe_nt
>>>"Event Log" }
>>>
>>>Debugging on the client side shows that the only thing the client nrpe
>>>gets is "Event" in stead of "Event Log". I've even tried adding
>>>additional double quotes, escaped quotes, etc with no luck.
>>>
>>
>>Have you tried to backslash escape the space like this:
>>Event\ Log
>>Or perhaps with the quotes:
>>"Event\ Log"
> 
> 
> Thanks Garry.
> 
> I just tried it both ways and I get the same result where the client
> receives "Event" instead of "Event Log". I think it may be that nrpe or
> windows do not respect the escaped space.
> 
> 
In order to pass an escape sequence on to another process you need to 
escape the escape as well, like so: \\\X
The first '\' will be stripped in the first passing, but the second '\' 
will be kept since it's escaped. The third '\' escapes the actual 
character to escape, so that it gets passed properly.


>>>Granted, there may be a better way to handle this altogether
>>>but this is
>>>the simplest form I could come up with. This is why I think having a
>>>configurable -a command separator may help.
>>>
>>>Arnold
>>
>>Garry W. Cook, CCNA
>>Network Infrastructure Manager
>>MACTEC, Inc. - http://www.mactec.com/
>>303.308.6228 (Office) - 720.220.1862 (Mobile)
>>
> 
> 
> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by: Oracle 10g
> Get certified on the hottest thing ever to hit the market... Oracle 10g. 
> Take an Oracle 10g class now, and we'll give you the exam FREE.
> http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
> _______________________________________________
> Nagiosplug-help mailing list
> Nagiosplug-help at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagiosplug-help
> ::: Please include plugins version (-v) and OS when reporting any issue. 
> ::: Messages without supporting info will risk being sent to /dev/null
> 

-- 
Mvh
Andreas Ericsson
OP5 AB
+46 (0)733 709032
andreas.ericsson at op5.se




More information about the Help mailing list