New Module IDEA

joerg.helmert at aracomp.de joerg.helmert at aracomp.de
Tue Mar 23 23:22:09 CET 2004


Hi Jeff,

I like the idea of checking multiple things with one service definition.
I compare it to the way, check_disk works.
I would not like to define a service for each mounted disk ;-)

But with check_disk you see a possible solution for passing back the results
of a "multicheck" to nagios.
Each single check_result is enclosed in "[]".
What is missing, is the state of the single check.
(at least this is what I remember from the last time I had a CRITICAL on
free disk space).

I'm currently writing a plugin to check /proc/meminfo on Linux. Maybe this
has already been done, but I use it as easy enough to learn.

There I extended the idea of passing results enclosed in "[]".
I add one "!" for WARNING state and two ("!!") for critical.
E.g. [www.statOK.com][!www.stateWARNING.com][!!www.stateCRITICAL.com]

Its not to easy readeable in Nagios' status output, but if that multicheck
is CRITICAL one'll of course have a close look.

I think, this would also help with the Email problem.
You would have to send only Plugin Result within your email and have all
information.

Also response time could be added.
E.g [www.first.com 0.123s][www.slow.com 8.456s]

What do you think about that?

Of course suppressing the good ones is also possible with that plugin output
but may not be needed.


I saw another approach within the sap-plugins, available from one of Suse's
ftp-servers.
Since nagios does only show the first line of plugin output, these plugins
are able to return results in a html-table.
This is done using nagios style sheets so that output of a single check is
colorized according its own state.
They send html-table structures instead of "\n" so Nagios "thinks" it is one
line. But in html it is more than one.

I'm currently testing this too with my plugin for /proc/meminfo.

It has an option -t (stands for tabular).
If this option is set, the erroneous results are shown in an html-table.
I also added -t all which shows every single check and ist result in correct
state color as plugin output.

There's one caveat:
The html output produces lots of unvisible characters, which will be counted
against MAX_PLUGIN_OUTPUT and another limiting value (currently at home, can
provide it tommorrow).
Default is around 380 characters. So output of big tables will be truncated.
I increased these values up to 2048.

Again, what do you think?


One thing at the end:
I think the approach with a shell script checking urls one by one has one
caveat:
If several urls show slow response times, the plugin will need a long time
to finish.
I'm testing with www.yahoo.com and had response times up to 8 seconds till
now.
I saw even more on high loaded pages fed from databases.
Solution would be, to run the checks in parallel.
Do you think it is woth the effort?
Maybe it would be better to change from bash to something else?

Sorry for the lengthy email,
Happy checking,

Joerg


> -----Original Message-----
> From: nagios-users-admin at lists.sourceforge.net 
> [mailto:nagios-users-admin at lists.sourceforge.net] On Behalf 
> Of jeff vier
> Sent: Tuesday, March 23, 2004 6:42 PM
> To: Josh
> Cc: nagios-users
> Subject: Re: [Nagios-users] New Module IDEA



-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id70&alloc_id638&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list