Nagios

Large Installation Tweaks


Up ToUp To: Contents
See Also See Also: Performance Tuning, Distributed Monitoring, Fast Startup Options

Introduction

Users with large Nagios installations may benefit from the use_large_installation_tweaks configuration option. Enabling this option allows the Nagios daemon to take certain shortcuts which result in lower system load and better performance.

Effects

When you enable the use_large_installation_tweaks option in your main Nagios config file, several changes are made to the way the Nagios daemon operates:

  1. No Summary Macros In Environment Variables - The summary macros will not be available to you as environment variables. Calculating the values of these macros can be quite time-intensive in large configurations, so they are not available as environment variables when use this option. Summary macros will still be available as regular macros if you pass them to to your scripts as arguments.

  2. Different Memory Cleanup - Normally Nagios will free all allocated memory in child processes before they exit. This is probably best practice, but is likely unnecessary in most installations, as most OSes will take care of freeing allocated memory when processes exit. The OS tends to free allocated memory faster than can be done within Nagios itself, so Nagios won't attempt to free memory in child processes if you enable this option.

  3. Checks fork() Less - Normally Nagios will fork() twice when it executes host and service checks. This is done to (1) ensure a high level of resistance against plugins that go awry and segfault and (2) make the OS deal with cleaning up the grandchild process once it exits. The extra fork() is not really necessary, so it is skipped when you enable this option. As a result, Nagios will itself clean up child processes that exit (instead of leaving that job to the OS). This feature should result in significant load savings on your Nagios installation.