strange behaviour when plugin output is containing the string "\n" in Nagios 3.0rc1
Marcus Hildenbrand
marcus.hildenbrand at sap.com
Thu Dec 27 11:34:26 CET 2007
Hi,
if a plugin is containing the string "\n" in its output I found some strange
output in status_file. For example if the output of the plugin looks like this:
# some_plugin
test\ntmon\test\abc
# echo $?
0
#
the status_file for this service is containing lines like this:
servicestatus {
...
...
plugin_output=test\
long_plugin_output=tmon\\\\test\\\\abc\n
...
...
}
Also the trailing \ in plugin_output line sometimes seems to confuse the CGI's
in a way that they are dumping:
# setenv REQUEST_METHOD POST
# setenv CONTENT_LENGTH 4
# echo all | ./tac.cgi
Segmentation fault (core dumped)
Is this a bug in Nagios or is it not allowed that the plugin output contains \n?
Thanks and regards
Marcus
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
More information about the Developers
mailing list