I upgraded recently from 3.5 to 4.0.8.
In 3.5, I made some tests to check the behavior of LONGSERVICEOUTPUT: I formated the output of my plugin as explained in the documentation, and expected things happened.
Now, with 4.0.8 it seems to me that there is a new bug in the decoding of plugin output...
I wrote a very simple plugin which return exactly the output showed in the documentation: http://nagios.sourceforge.net/docs/nagi ... inapi.html ("DISK OK - free...").
And when I look at the GUI, the example of the documentation is not decoded as explained by the documentation.
It is decoded in the following way:
Status Information: DISK OK - free space: / 3326 MB (56%):
Performance Data: /=2643MB;5948;5958;0;5968 / 15272 MB (77%); /boot 68 MB (69%); /home 69357 MB (27%); /var/log 819 MB (84%); | /boot=68MB;88;93;0;98 /home=69357MB;253404;253409;0;253414 /var/log=818MB;970;975;0;980
Changes in version 4.0.8 for LONGSERVICEOUTPUT?
Re: Changes in version 4.0.8 for LONGSERVICEOUTPUT?
Could you post your plugin and how the check command is defined so we can review it?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Changes in version 4.0.8 for LONGSERVICEOUTPUT?
To answer you, I tried to write a very simple plugin (simplier than my plugin having problems). And I associated this plugin to a brand new service.
And it works as expected and as the documentation says.
So the problem comes from elsewhere...
Code: Select all
#! /bin/bash
echo 'DISK OK - free space: / 3326 MB (56%); | /=2643MB;5948;5958;0;5968
/ 15272 MB (77%);
/boot 68 MB (69%);
/home 69357 MB (27%);
/var/log 819 MB (84%); | /boot=68MB;88;93;0;98
/home=69357MB;253404;253409;0;253414
/var/log=818MB;970;975;0;980'
exit 0
So the problem comes from elsewhere...
Re: Changes in version 4.0.8 for LONGSERVICEOUTPUT?
So it is working after all?
Are you using mod_gearman? (there was a newline bug with core4 and gearman)
Are you using mod_gearman? (there was a newline bug with core4 and gearman)
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Re: Changes in version 4.0.8 for LONGSERVICEOUTPUT?
My fault!
For convenience, I wrapped my own plugins with a shell script that makes various things related to my project.
And in that shell script, I wrote
echo $called_nagios_plugin_output
instead of
echo "$called_nagios_plugin_output"
Without the quotes, the shell script eats my end of lines.
Problem is now fixed and thanks for your interaction.
For convenience, I wrapped my own plugins with a shell script that makes various things related to my project.
And in that shell script, I wrote
echo $called_nagios_plugin_output
instead of
echo "$called_nagios_plugin_output"
Without the quotes, the shell script eats my end of lines.
Problem is now fixed and thanks for your interaction.