|
From: Subhendu G. <sg...@sg...> - 2002-09-04 20:58:19
|
Everything looks good except for the exit state for the check_notes=20 plugin. When the check_notes plugin terminates with a Critical, what is the exit=20 code being used? If you are using just "exit" that implies "exit 0"=20 which is OK. You need to exit with "exit 2" for a critical status. -sg On Wed, 4 Sep 2002, Edgard Dap=E1s wrote: >=20 > I write my pluging check_notes: >=20 > 1- I declare it on the nrpe.cfg (client machine) > # grep check_notes nrpe.cfg > command[check_notes]=3D/usr/local/netsaint/check_notes.sh >=20 > 2- I declare the plugin in netsaint machine, file host.cfg >=20 > # grep check_notes hosts.cfg >=20 > service[dsl102]=3DNOTES;0;24x7;1;2;1;webpin;120;24x7;1;1;0;;check_nrpe!= check_notes >=20 >=20 > 3- when I run the command from the prompt I get the following responce >=20 > When the notes is down: > # /opt/sfw/lib/netsaint/plugins/check_nrpe 10.74.72.43 -c > check_notes > Critical >=20 > When the notes is UP > # /opt/sfw/lib/netsaint/plugins/check_nrpe 10.74.72.43 -c > check_notes > OK >=20 > 4- In the status.log, I have the followin message, when the service is = UP >=20 > [1031166917] SERVICE;dsl102;NOTES;OK;1/1;HARD;1031166845;1031166965;ACT= IVE;1;1;1;1031129137;0;OK;69196;0;0;400;0;0;1;0;0;1;0;0.00;0; > OK >=20 > when the service is down, i have the folowing message >=20 > [1031166917] SERVICE;dsl102;NOTES;OK;1/1;HARD;1031166845;1031166965;ACT= IVE;1;1;1;1031129137;0;OK;69196;0;0;400;0;0;1;0;0;1;0;0.00;0; > Critical >=20 > But, only status information change, the current status only change wh= en the plugin can't be execute. >=20 > Should I declare my plugin like a new command in the COMMAND CONFIGURAT= ION section in the hosts.cfg >=20 > Thanks >=20 >=20 >=20 >=20 >=20 >=20 >=20 >=20 > Subhendu Ghosh <sg...@sg...>@lists.sourceforge.net con fecha > 04/09/2002 15:58:32 >=20 > Enviado por: net...@li... >=20 >=20 > Destinatarios: net...@li... > CC: > Asunto: Re: [Netsaintplug-help] Writing a new plugin >=20 >=20 > On Wed, 4 Sep 2002, Edgard Dap=E1s wrote: >=20 > > > > Just one question > > > > I write a plugin, do I have to declare it in the hosts.cfg or in > > command.cfg? > > > > Even if I want to execute it in a remote machine? > > > > Could you send me an example, please > > > > Because, I have problem with the service status > > > > Thanks > > >=20 > Take a look at the plugin developers guidelines on the nagiosplug > homepage. >=20 > If you are going to execute it on a remote system, are you using NRPE a= s a > conduit between the monitoring host and the target? If so, you need an > entry for the plugin and all its parameters in nrpe.cfg. >=20 > On the netsaint side, you need an entry for check_nrpe in commands.cfg > (should be there already) and an entry in hosts.cfg for a service check > using check_nrpe with arg=3Dplugin name defined in nrpe.cfg >=20 > Hope this helps. > -- >=20 > -sg >=20 >=20 >=20 > ------------------------------------------------------- > This sf.net email is sponsored by: OSDN - Tired of that same old > cell phone? Get a new here for FREE! > https://www.inphonic.com/r.asp?rsourceforge1&refcode1vs3390 > _______________________________________________ > Netsaintplug-help mailing list > Net...@li... > https://lists.sourceforge.net/lists/listinfo/netsaintplug-help > http://netsaintplug.sf.net/ > http://sf.net/projects/netsaintplug/ >=20 >=20 >=20 >=20 >=20 >=20 > ------------------------------------------------------- > This sf.net email is sponsored by: OSDN - Tired of that same old > cell phone? Get a new here for FREE! > https://www.inphonic.com/r.asp?r_______________________________________= ________ > Netsaintplug-help mailing list > Net...@li... > https://lists.sourceforge.net/lists/listinfo/netsaintplug-help > http://netsaintplug.sf.net/ > http://sf.net/projects/netsaintplug/ >=20 --=20 |