Introduction

The dbWatch Nagios extension mechanism consists of two parts. First, a jar file called nagiospump.jar that causes dbWatch to export its status to a text file. Second a Nagios plugin called Nagios_Fileread.pl that imports the status in the text file into Nagios.

These files can be downloaded from here:
https://download.dbwatch.com/download/extensions/nagios/

Installing

The first thing you must do is to tell dbWatch to export the nagios text file. In order to do this place the file nagiospump.jar in the [dbWatch Server]/server/extensions/ catalog. Then (in the dbWatch Monitor) click on the «Server->Server Extensions» menu.

Here you should now see an entry called «Nagios Extension». Select it and click «Configure». In the configuration view you can specify the filename for the generated text file, as well as how long dbWatch should wait before generating the file for the first time («firstrelay») and how often the file should be updated («relayperiod»).

When you are satisfied with the settings, click «OK». Then select the Nagios Extension again, and click «Enable». The entry should then turn white.

dbWatch will now (with the default configuration) generate the «nagios_output.txt» file after 70 seconds, and update it once every minute. Please verify that this file is generated before moving onto the next step

Installing the Nagios Agent

If you already have an agent installed on the computer running the dbWatch Server, you can skip this step.

A common agent for Nagios is NSClient++, that is what we will use in this guide. The agent can be downloaded from the following page: http://sourceforge.net/projects/nscplus. Once you have downloaded and installed the agent, there are a couple of steps that must be completed.

First, place the Nagios_Fileread.pl file in the NSClient++/scripts catalog.
Then open the NSC configuration file located in the NSClient++ catalog, and make the following changes:

  • Uncomment the «CheckExternalScripts.dll» (remove the «;» sign) entry under the «Modules» section.
  • Set the allowed_hosts entry to the ip address of the Nagios instance in the «Settings» section.
  • Set allow_arguments=1 under the NRPE section.
  • Set allow_nasty_meta_chars=1 under the NRPE section.
  • Add the following line to the «External Scripts» section (with the correct path to Nagios_Fileread.pl): ‘‘check_dbwatch_win=perl “C:\Program Files\NSClient+
    +\scripts\Nagios_Fileread.pl” $ARG1$’‘

(A sample NSC configuration file should be attached with this document.)
You can now start the NSClient++ service.

Installing Perl

In order for Nagios_Fileread.pl to work, perl must be installed on the host running dbWatch. If perl is already installed, skip to the next step. Otherwise, visit http://www.perl.com/download.csp to download and install perl.

Adding the dbWatch host to Nagios

Add the host running the dbWatch Server to Nagios by using the Nagios Monitoring Wizard.

Configure Nagios

Add command

In Nagios, using the Nagios Core Config Manager, add a command called check_dbwatch_win, with the command line «perl C:\Program Files\NSClient++\scripts\Nagios_Fileread.pl $ARG1$», using the correct path to the perl script.

Add Service

  • In Nagios, using the Nagios Core Config Manager, add a service called dbWatch.
  • Set Config Name* to the hostname of the computer running dbWatch.
  • Select the host running dbWatch under Hosts*.
  • Set Check command* to «check_nrpe».
  • Set $ARG1$ to «check_dbwatch_win».
  • Set $ARG2$ to «-a “C:/Programfiler/dbWatch/9.2_7408/nagios_output.txt”», again using the correct path to the text file produced by dbWatch.

Conclusion

dbWatch should now appear under Views->Service Detail in Nagios

← Nimsoft/Nimbus / SCOM

Feedback

Was this helpful?

Yes No
You indicated this topic was not helpful to you ...
Could you please leave a comment telling us why? Thank you!
Thanks for your feedback.

Post your comment on this topic.

Post Comment