Re: Nagios 4.3.1 not accepting single quote '
Posted: Wed Jun 28, 2017 11:54 am
I setup a 3.5.1 system and a 4.x.x server.
I then created the nagios command like the example below
I then enabled debugging in the NSClient agent and this is how the command was received.
So it looks like Core 3.5.1 changes the single quote to double quotes and removes the second back slash.
On the core 4.x.x server I created the command like the following
this is how the command was received by NSClient.
All that was done was the change of single quotes to double quotes.
It looks like Nagios Core always changed the single quotes to double quotes but core 3.5.1 removed the extra \ from the command.
In core 4.x.x, you can still use the single quote but you cannot use the double back slashes as it seems from the testing I did.
I then created the nagios command like the example below
Code: Select all
'\\LogicalDisk(C:)\\Avg. Disk sec/Write'Code: Select all
Created command: show-all "\LogicalDisk(C:)\Avg. Disk sec/Write" perf-config=*(suffix:none)On the core 4.x.x server I created the command like the following
Code: Select all
'\LogicalDisk(C:)\% Free Space'Code: Select all
Created command: show-all "\LogicalDisk(C:)\% Free Space" perf-config=*(suffix:none)It looks like Nagios Core always changed the single quotes to double quotes but core 3.5.1 removed the extra \ from the command.
In core 4.x.x, you can still use the single quote but you cannot use the double back slashes as it seems from the testing I did.