Nagios does not display information after the (|) pipe
Posted: Thu Oct 27, 2016 3:43 am
Good morning,
I've got a plugin working and am currently writing a bash script to run the check and report the status to Nagios. When I run my command on the RHEL server locally I get all the information that I'm looking for:
./check_sap_bash
EU_PUT History = EU_PUT | 00102301 | Be▒ind. |, started at 2016-10-27,00:10:24 finished at 2016-10-27,00:10:31
But Nagios only displays 'EU_PUT History = EU_PUT'. I want to write my plugin to check for a string in the output, in this case 'Be▒ind.'. But the information is not reaching Nagios and therefor I cannot use it. I cannot modify the output. So my question:
Is there a way to make Nagios see the information that follows the pipe symbol? How do people manage writing their own custom checks when facing the pipe symbol?
Kind regards,
Dennis Lans
I've got a plugin working and am currently writing a bash script to run the check and report the status to Nagios. When I run my command on the RHEL server locally I get all the information that I'm looking for:
./check_sap_bash
EU_PUT History = EU_PUT | 00102301 | Be▒ind. |, started at 2016-10-27,00:10:24 finished at 2016-10-27,00:10:31
But Nagios only displays 'EU_PUT History = EU_PUT'. I want to write my plugin to check for a string in the output, in this case 'Be▒ind.'. But the information is not reaching Nagios and therefor I cannot use it. I cannot modify the output. So my question:
Is there a way to make Nagios see the information that follows the pipe symbol? How do people manage writing their own custom checks when facing the pipe symbol?
Kind regards,
Dennis Lans