[Nagiosplug-devel] devloper guidelines..

Volker.Aust at premiere.de Volker.Aust at premiere.de
Wed Jul 17 00:31:02 CEST 2002


> -----Original Message-----
> From: Subhendu Ghosh [mailto:sghosh at sghosh.org]
> Sent: Monday, July 15, 2002 3:04 PM
> To: nagiosplug-devel at lists.sourceforge.net
> Subject: RE: [Nagiosplug-devel] devloper guidelines..
> 
> 
> On Mon, 15 Jul 2002 Volker.Aust at premiere.de wrote:
> 
> > I'm using named subroutines too. Is this restriction only 
> important when
> > using ePN? Currently I'm not using ePN. Is there any 
> possibility to test a
> > perl plugin for conformity with ePN beside to have a second 
> installation?
> 
> look at mini_epn in the nagios/contrib directory - no need 
> for a secondary 
> installation.

Thank you. Works.

> 
> Yes, the restrictions are only for embedded perl, but the performance 
> gains of ePN are pretty large so all the standard plugins 
> should support 
> ePN. 
> 
> Named subroutins are fine - just not nested named 
> subroutines...  I'll 
> update the docs to reflect the change.
> 
> -sg

I request another update for the docs. It apply to the argument passing to
the plugins. Normaly Nagios calls a shell which calls the plugin. With ePN
Nagios calls directly the plugin. The difference is showing then you have
arguments with spaces. Normaly I quote the entire argument with single or
double quotes. The quotes are removed by the shell and the entire argument
is passed to the plugin. With ePN it is different. The argument is separated
at the spaces and each part is passed to the plugin. Eg. I want to pass a
service (-s "Net Logon") to a plugin (which checks a NT/W2K service over
SNMP from the Lan Manager MIB). The plugin gets 3 arguments passed ('-s',
'"Net' and 'Logon"'). To solve the problem for me I have decided to url
escape all spaces in the argument ('-s Net%20Logon') and unescape it in the
plugin. My tests with mini_epn show's that it works.

> 
> 
> > 
> > To the naming: I'm a friend of verbose names. My scheme is 
> to include not
> > only the 'transport' for the check (_snmp_, _smb_, ...) but 
> also the source
> > of the information. I have several plugins which get their 
> information over
> > SNMP from diffent MIB's. Eg.
> > 
> > check_snmp_cim_cpu	cpu utilization from Compaq Insight Manager
> > check_snmp_cim_fs		filesys utilization from CIM
> > check_snmp_cim_therm	thermal status from CIM
> > check_snmp_lm_service	service check from Lan Manager 
> MIB for NT/W2K
> > check_snmp_rdbms_???	(not started coding because 
> waiting for an answer
> > from IBM relating DB2 and SNMP)
> > 
> 
> I have a preference for verbose naming as well although in 
> this particular 
> case, I might have been confused between CIM the tecnology 
> for DMTF and 
> the compaq insight manager.
> 

Ok. I have named it check_snmp_cpq_???.

> 
> 
> > What do you think?
> > 
> > -vol
> > 
> > > -----Original Message-----
> > > From: Subhendu Ghosh [mailto:sghosh at sghosh.org]
> > > Sent: Thursday, July 11, 2002 6:56 PM
> > > To: NagiosPlug Devel
> > > Subject: [Nagiosplug-devel] devloper guidelines..
> > > 
> > > 
> > > about named subroutines restrictions..
> > > 
> > > Perhaps that should be nested named subroutines?
> > > see:
> > > http://perl.apache.org/guide/perl.html  
> > > 
> > > I use named subroutines all the time :)
> > > 
> > > Stanley - any comments?
> > > 
> > > -- 
> > > 
> > > -sg
> > > 
> > > 
> > > 
> > > -------------------------------------------------------
> > > This sf.net email is sponsored by:ThinkGeek
> > > PC Mods, Computing goodies, cases & more
> > > http://thinkgeek.com/sf
> > > _______________________________________________
> > > Nagiosplug-devel mailing list
> > > Nagiosplug-devel at lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/nagiosplug-devel
> > > 
> > 
> > 
> > -------------------------------------------------------
> > This sf.net email is sponsored by:ThinkGeek
> > Welcome to geek heaven.
> > http://thinkgeek.com/sf
> > _______________________________________________
> > Nagiosplug-devel mailing list
> > Nagiosplug-devel at lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/nagiosplug-devel
> > 
> 
> -- 
> 
> 
> 
> 
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Nagiosplug-devel mailing list
> Nagiosplug-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagiosplug-devel
> 




More information about the Devel mailing list