Search Exchange

Search All Sites

Nagios Live Webinars

Let our experts show you how Nagios can help your organization.

Contact Us

Phone: 1-888-NAGIOS-1
Email: sales@nagios.com

Login

Remember Me

CheckDaemon

Rating
0 votes
Favoured:
0
Hits
145246
Files:
FileDescription
run_background_checks.plVersion 0.3

Help Support Ethan Galstad's New Project:

Help Support Ethan

A Message From The Founder...

As the founder of Nagios, I'm asking for your help in a cause that's dear to my heart.

I'm launching a new project to help better the world by providing the information, ideas, and inspiration that I believe can improve the lives of people everywhere.

I know you're busy managing networks, but I would appreciate it if you would consider liking my Facebook page and showing your support for the content and messages I produce by sharing them with your friends and family.

You can learn more about my project by visiting ethangalstad.me/nagios. Thank you for your time. I wish you all the best in your endeavors, whatever they may be.

- Ethan

A perl script/package to run Nagios checks in the background without the limitations of Nagios executing the checks.
When Nagios is busy, it will occasionally not execute checks, and simply schedule them to be executed in the future, on the basis that the machine should not be overloaded. After you've seen a once-per-minute check continually rescheduled and never executed for a continious period of six hours, this feature of Nagios becomes a little bit annoying.

Enter run_background_checks.pl/Nagios::CheckDaemon . This script is designed to be executed from cron or Nagios (as a perfdata_processing_command with a long interval) and has one job; to execute host and service checks.

With this narrow goal in mind, this script parses the Nagios configuration files, and periodically keeps up to date with the current state of Nagios via the defined status_file. Host and Service Checks are executed (at their scheduled times!) in a parallel fashion up to max_concurrent_checks (and cpu load limits), and are submitted to Nagios via the pipe defined in the external_command_file option.

Checks which are past their expected execution time, based on the last update time plus the appropriate interval are executed immediately, rather than being rescheduled for the future. Check execution dependencies are also followed, ensuring no surprises are present. Checks which are not configured to accept passive check results are not executed.

Some patches to the dependent Nagios::Object libraries are required, see the home page.