Librenms

During my engineering apprenticeship, I had to deploy a new monitoring tool.

We chosed LibreNMS, and the only way for us to monitor all our clients infrastructures, was the distributed mode.

LibreNMS is a really cool and modern monitoring tool, that fit our needs.

The project

For you to understand how we use LibreNMS and distributed polling, the schema is the following.

librenms distributed

So, we have VPN link between central and remote clients site.

Each clients are a company, and we deploy an agent in each company.

I also use a single instance of MySQL, RRDCached and Memcached.

The Script

The scripts used are there :

https://github.com/guillaume-minesales/librenms_auto

Pre requisite

You need to change the following value, according to your setup :

Config.php file

  • Replace “ip_of_central_server” by your own central server ip.
  • “distributed_poller_group” change this value, according to the id group.
  • Custom “community” field whith your own. The “Public” community could be a security flaw…

Config_php.sh

You can change the timezone according to your own OS timezone.

In my case, it’s set to : Europe/Paris.

Some basics

You need to set your system hostname before executing the script.

Usage

You need to execute in the following order :

./requirements_soft_install.sh | tee logs/install.log

./config_apache.sh | tee logs/apache.log

./config_php.sh | tee logs/php.log

You don’t need to do more, and in central LibreNMS instance you’ll see the poller coming to life!

You can add devices on your remote site now!