Skip to content
This repository has been archived by the owner. It is now read-only.

[ #2948] remove embedded perl from core, add a dedicated worker #1063

icinga-migration opened this issue Aug 5, 2012 · 3 comments


Copy link

@icinga-migration icinga-migration commented Aug 5, 2012

This issue has been migrated from Redmine:

Created by mfriedrich on 2012-08-05 10:25:52 +00:00

Assignee: mfriedrich
Status: Closed (closed on 2012-08-22 18:19:29 +00:00)
Target Version: exp
Last Update: 2012-08-22 18:19:29 +00:00 (in Redmine)

since #2904 and such opens the way to the core not actually calling any check commands anymore, it does not make sense to keep this functionality within the core itsself, but write a dedicated worker for those checks (as already suggested within #2910).

this should revoke all config and configure options, and only add new ones if such a worker is required.

note though - this highly depends how the worker architecture play well on testgrounds, unless this is not the case, this issue won't hit any upstream release.

core: Remove embedded perl
For several years it's been the most complex, the buggiest and the
least tested part of Nagios, and people experiencing problems with
the Nagios core have always gotten the suggestion to disable the
embedded perl interpreter and its broken caching, and it's been
all but impossible to test its functionality with all the different
versions of Perl available.

Besides; Since we run checks through workers now instead of forking
directly and larger processes cause slower fork()'s, it's likely we
already have better check performance than adding X MiB's of heap
memory that we'd have to earmark for caching pre-compiled perl
plugins if we were to support it again.

A much more feasible way forward is to use a module to distribute
certain checks to a specialized worker. Using the newly introduced
libnagios, it shouldn't take very long to write such a one.

Signed-off-by: Andreas Ericsson 


2012-08-05 10:56:21 +00:00 by mfriedrich 622500ef1389d68cced92cdf628f580c5c364812

core: remove embedded perl functionality and libs #2948

this affects mainly the libs ( and the tools in contrib) as well
as function header's removal, as well as dropping all #ifdef's from the

as noted in #2948, we should implemented embedded perl again in (a)
dedicated core worker(s) (see #2910). needed files can be restored from git history
if needed, so we'll wipe the for now. furthermore, the configure options
should be renamed to reflect that the workers will require embedded perl
(this should rather happen within libicinga too).

the main reason for dropping embedded perl at first sight is as well -
the past showed that the cached perl checks leak memory, and the
performance gain resulted in memory bloated processes on the checks.
some people created a cron restarting their daemon every night, others
just might use mod_gearman where the workers have their own embedded
perl implemented (and will be restarted once every while). and others
just let the core fork into a child calling the script interpreter -
saving memory, but hogging the cpu a bit more. the last option should
work even better with the worker jobs, not blocking the core anymore,
passing the checkresults back in memory too.

refs #2948

2012-08-05 11:53:45 +00:00 by mfriedrich 38658eb65407e68cf85e1448eebe1f2bc6b82d0f



refs #2948



This comment has been minimized.

Copy link
Member Author

@icinga-migration icinga-migration commented Aug 5, 2012

Updated by mfriedrich on 2012-08-05 10:54:42 +00:00

speciality on icinga

  • will be output from configure
  • spec file makes use of custom configure option


configure option deprecated
--enable-embedded-perl (should be renamed for workers)

file changes (deleted)

functions - all perl functions within the core code removed.

-int init_embedded_perl(char **);                       /* initialized embedded perl interpreter */
-int deinit_embedded_perl(void);                                /* cleans up embedded perl */
-int file_uses_embedded_perl(char *);                   /* tests whether or not the embedded perl interpreter should be used on a file */

This comment has been minimized.

Copy link
Member Author

@icinga-migration icinga-migration commented Aug 7, 2012

Updated by mfriedrich on 2012-08-07 16:48:30 +00:00

  • Target Version set to exp

This comment has been minimized.

Copy link
Member Author

@icinga-migration icinga-migration commented Aug 22, 2012

Updated by mfriedrich on 2012-08-22 18:19:29 +00:00

  • Status changed from Assigned to Closed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.