Centerity – Development of check “MaxDB Data Area usage”

This page describes the development of checking the “Data Area usage” of a MaxDB database by Centerity.

Advantages of this setup :
* no extra scheduling is needed on the database server
* warning and critical values for the “Data Area usage” can be maintained by using Centerity.

Disadvantage is that this setup requires a hard-coded password for MaxDB database user.
It’s not possible for the Perl script to use a Xuser file (via Centerity). This will result in error message “Error! XUser not found!”

Usage of a hard-coded password for MaxDB database user is not acceptable for my company, so we had to change the setup. See Centerity – Development of check “MaxDB Data Area usage” v2  for the update, which uses Xuser file.

Versions used :
Centerity Monitor Enterprise Edition : 3.9.5
MaxDB database :
Linux : RedHat 6
Perl : 5.10.1
Nagios check_maxdb script : 0.50

The Perl script that will be used to check the “Data Area usage” of a MaxDB database, is based on Nagios check_maxdb script (, created by Mark Rittinghaus.

MaxDB database server setup

Copy to the MaxDB database server, to the directory where all Nagios custom checks are located.

Update with local settings (server name, database name, password of MaxDB control user).

Add following custom check to your Nagios config file, probably located in /usr/local/nagios/etc/conf.d :
command[maxdb_data_area_check]= <directory location> -t D -w $ARG1$ -c $ARG2$

To check the service on the MaxDB database server (see Nagios: How to Enable check_nrpe Command Line Arguments for the original post) :

Modify nagios user in /etc/passwd : change /sbin/nologin to /bin/bash

Logon to database server as nagios user.

-bash-4.1$ /usr/local/nagios/libexec/check_nrpe -H <ip address of database server> -c maxdb_data_area_check -a 90 95
OK: Data Area used 2.53% (355MB/14000MB)

Note : in case of error message “CHECK_NRPE: Error – Could not complete SSL handshake” :
* add ip address of database server to allowed_hosts in file /usr/local/nagios/etc/nrpe.cfg
* restart nrpe service

MaxDB database server setup is ready now, let’s configure Centerity !

Centerity setup

In Centerity, create service command check_maxdb_data_area

Next, create service SDB – MaxDB Data Area usage
Tab General :

Tab Commands :

Final result in Centerity Monitor :


Geef een reactie

Het e-mailadres wordt niet gepubliceerd. Vereiste velden zijn gemarkeerd met *