Cool Solution - Monitoring UCC with nagios

From Univention Wiki

Jump to: navigation, search
Produktlogo UCS Version 4.1
Produktlogo UCC Version 3.0

Note: Cool Solutions are articles documenting additional functionality based on Univention products. Not all of the shown steps in the article are covered by Univention Support. For questions about your support coverage contact your contact person at Univention before you want to implement one of the shown steps.

Also regard the legal notes at Terms of Service.

It's relatively easy to use Nagios to monitor UCS servers. The idea here is to show how to integrate Univention Corporate Clients (UCC) into the monitoring setup of an UCS Nagios server.

We will first install the NRPE packages (Nagios Remote Plugin Executor) in UCC to make the system a Nagios client. As part of the setup, we need to manually copy Nagios plugins to UCC.

Finally, the Nagios server has to be aware of these new clients to monitor. For that, we will enable the Nagios services for the UCC hosts.

UCC setup (Nagios client)

Note: In some environments, it would be preferable to perform these steps within the image file before a roll out (by mounting it as described in the UCC manual).

Install the Nagios NRPE packages (agent and plug-ins):

apt-get install nagios-nrpe-server

Open /etc/nagios/nrpe.cfg with an editor and allow the Nagios server as host in the nrpe.cfg file:

#---
allowed_hosts=server.example.com
#---

Now you need to copy the needed Univention plug-ins from your Nagios server onto our UCC system:

scp server.example.com:/etc/nagios/nrpe.univention.d/* /etc/nagios/nrpe.d/

Note: If working on the UCC image, it could be better to move the files before performing the chroot to it.

Restart NRPE service

service nagios-nrpe-server restart

Note: This won't have any effect if you are modifying an UCC image.

UCS setup (Nagios server)

The next step is to set the UCC host to be monitored.

For this, you have to open the Univention Management Console and switch to the "Computers" module.
Now open the settings of the UCC host, switch to the "Options" tab and tick the "Nagios support" option
As the final step, you have to assign the Nagios services "UNIVENTION_DISK_ROOT" and "UNIVENTION_PING" in the "Advanced settings" tab below "Nagios services".

Now you should be able to see the computer in your Nagios web interface. After some minutes the plug-ins will start returning status information to the Nagios server.

References

Personal tools