[PATCH] common/macros.c:2185:grab_standard_servicegroup_macro() speed up & Service check execution problem report

Jochen Bern Jochen.Bern at LINworks.de
Tue Jan 4 11:33:00 CET 2011


On 01/04/2011 10:38 AM, Andreas Ericsson wrote:
> On 01/04/2011 04:37 AM, Stephane LAPIE wrote:
>> 3) Which brings me to a feature request : Nagios does not cache the
>> generation output of standard macros such as service group members
>> (derivated from configuration, and therefore static within any given
>> Nagios process), and has to go through the process of regenerating the
>> list every single time a child process is executed and environment
>> macros are set. This is extremely time-consuming, and further
>> performance improvements could be achieved through this.
> Such a performance increase would come at a fairly costly price though,
> since Nagios fork()'s each time it runs a check and the memory would
> be duplicated to each child. Most of it should be shared on Linux, but
> for Solaris, BSD and others it might prevent Nagios from running
> altogether, and it would be a complete and utter waste to stash them
> if environment variables are turned off and they're never used in a
> real command, as is expected for large installations.

Wild idea: How about "cacheing" them into dotfiles that the plugins'
interpreter can "source" (C shells) / "." (Bourne shells) / whatever?

E.g., set $NAGIOS_HOSTGROUPNAME within Nagios itself (if env vars are
enabled) but have $NAGIOS_HOSTGROUPMEMBERS set by means of a
.../nagios/var/env-constants/HostGroup_$NAGIOS_HOSTGROUPNAME .

Regards,
								J. Bern
-- 
Jochen Bern, Systemingenieur --- LINworks GmbH <http://www.LINworks.de/>
Postfach 100121, 64201 Darmstadt | Robert-Koch-Str. 9, 64331 Weiterstadt
PGP (1024D/4096g) FP = D18B 41B1 16C0 11BA 7F8C DCF7 E1D5 FAF4 444E 1C27
Tel. +49 6151 9067-231, Zentr. -0, Fax -299 - Amtsg. Darmstadt HRB 85202
Unternehmenssitz Weiterstadt, Geschäftsführer Metin Dogan, Oliver Michel

------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl




More information about the Developers mailing list