Tag Archive for 'Documentation'

Unleashing the Power of Nagios — Utilizing the Actions Component

The “Action URL” component has been quietly deprecated in favor of the newer “Actions” component. The “Actions” component has been released for some time now and has been rolled up into the base install of XI. Although it is most commonly used to add URLs to specific Nagios objects on the details pages in XI, it is by far more advanced than its predecessor “Action URL”. The “Actions” component is truly one of the more powerful components available for Nagios XI, on par with event handlers in extensibility and complexity.

The use cases for the Actions component are near endless. A simple example would consist of the streamlining of repeated tasks, like the adding of common comments to particular hosts. This can be accomplished using the Actions component and the command pipe. For the following example, we will assume that the comment to be added to a host relates to the completion of a successful security audit by the user “auditor”. This action will include the passing of the %host% macro to a script that will write to the Nagios command pipe.

First create a script named “security_audit_completed.sh” in /usr/local/nagios/libexec. The script follows:

Continue reading ‘Unleashing the Power of Nagios — Utilizing the Actions Component’

Documentation: Writing Custom Wizards

We’ve had some requests in past months about developer documentation for writing custom Configuration Wizards for Nagios XI.  Many admins have a large amount of devices of a specific type that they regularly need to add to their monitoring environment.  So for those needing to write their own wizard, and don’t mind getting their hands dirty with PHP development, this document and example code illustrate how to write a monitoring wizard while maintaining the integrity of the Nagios XI framework.  The example wizard utilizes a weather alerts check plugin written by Tony Yarusso.  You can find the document on the Nagios Library.