Distributed Poller not working

Hi, I have been trying to set up the distributed poller for a while now and I’m not sure if I’m missing something or if it can’t be done for how I want to use it.

I have a second instance of Libre running with additional NICs because I want certain devices to only be added and polled on the secondary server, but still be connected to the primary server’s database.

If that’s not possible, my second option is to add all devices to my primary server, then have the certain devices use the secondary server for polling. Does LibreNMS recognize secondary NIC’s from a virtual server?

As for now, my primary server is not detecting my secondary server as a Libre server, even though I can ping it. Here’s my configurations for distributed polling that does not seem to be working.

Primary server: (Running Libre, MySQL, Apache, RRDTool 1.4.8, Memcached, RRDCached)

Database config

$config[‘db_host’] = ‘localhost’;
$config[‘db_port’] = ‘3306’;
$config[‘db_user’] = ‘myuser’;
$config[‘db_pass’] = ‘mypassword’;
$config[‘db_name’] = ‘mylibredb’;
$config[‘db_socket’] = ‘’;

$config[‘rrdcached’] = “unix:/var/run/rrdcached.sock”;

*** Distributed Poller Settings

$config[‘distributed_poller’] = true;
$config[‘distributed_poller_name’] = php_uname(‘n’);
$config[‘distributed_poller_group’] = ‘0’;
#$config[‘distributed_poller_memcached_host’] = ‘localhost’;
#$config[‘distributed_poller_memcached_port’] = ‘11211’;
#$config[‘rrdcached’] = “localhost:42217”;
#$config[‘update’] = 0;

Secondary Server: Running LibreNMS, MySQL, Apache, RRDTool 1.4.8. (memcached and rrdcached are installed but I have stopped the services)

Database config

$config[‘db_host’] = ‘localhost’;
$config[‘db_port’] = ‘3306’;
$config[‘db_user’] = ‘myuser’;
$config[‘db_pass’] = ‘mypassword’;
$config[‘db_name’] = ‘mylibredb’;
#$config[‘db_socket’] = ‘’;

#$config[‘rrdcached’] = “unix:/var/run/rrdcached.sock”;

Distributed Poller Configurations

$config[‘distributed_poller_name’] = php_uname(‘n’);
$config[‘distributed_poller_group’] = ‘1’;
$config[‘distributed_poller_memcached_host’] = “ip.ip.ip.ip (my primary server ip)”;
$config[‘distributed_poller_memcached_port’] = 11211;
$config[‘distributed_poller’] = true;
$config[‘rrdcached’] = “ip.ip.ip.ip (my primary server ip):42217”;
#$config[‘update’] = 0;

Both servers are using https. I dont know if that changes how I need to edit the poller configs.
I’ve also ran ./dist-poller.php -r on both servers.

Any help is greatly appreciated.

You only need one MySQL, RRDCached and Memcached installation. All your pollers point to these rather than installing them locally. With 1.4.8 of rrdtool you need to share your rrd folder over nfs.

I will need an nfs server is what you are saying? Or do you know the easiest way to upgrade rrdtool to an existing LibreNMS setup? My last attempt led to several OS errors.

Depends on your distro but if it doesn’t have an up to date rrdtool then you’ll have to build from source.

I’m using CentOS 7. My Libre build is 1.43-147-g3aeab9e

Did it with CentOS 7 and rrdtool 1.7.0 built from source and it work very well without NFS share…
You can get it from https://oss.oetiker.ch/rrdtool/pub/rrdtool-1.7.0.tar.gz

Thanks. This is what I tried before when I botched my libre install. I think it was 1.6.0 but I’ll have to look for better install instructions to update from 1.4.8 to 1.7.0.

Well this is what I did to migrate from the standard rrdtool from CentOS 7 to the 1.7.0

rpm -e rrdtool rrdtool-devel rrdtool-perl
cd /opt ; wget https://oss.oetiker.ch/rrdtool/pub/rrdtool-1.7.0.tar.gz
tar xvfz rrdtool-1.7.0.tar.gz
cd rrdtool-1.7.0
./configure
make ; make install
ln -s /opt/rrdtool-1.7.0/bin/rrdcached /usr/bin/rrdcached
ln -s /opt/rrdtool-1.7.0/bin/rrdtool rrdtool
ln -s /opt/rrdtool-1.7.0/bin/rrdcreate rrdcreate
ln -s /opt/rrdtool-1.7.0/bin/rrdupdate rrdupdate
ln -s /opt/rrdtool-1.7.0/bin/rrdcgi rrdcgi
systemctl enable --now rrdcached.service

I used similar steps and it failed stating I needed to upgrade library first. Error after running ./configure: “configure: error: you need either glib with g_regex support or libpcre to compile rrdtool.”
I have to go through the steps again of updating lib, that is when I botched the OS.

I think you need some prerequisites to build it; if i correctly remember epel repo and the following packages:
glib glib-devel cairo-devel libxml2-devel pango-devel pango libpng-devel freetype freetype-devel libart_lgpl-devel perl-devel

Thanks! That has helped a lot. Is your path to the binary file now ‘/opt/rrdtool-1.7.0/bin/rrdtool’?

Nope I made all the symbolic link under /usr/bin
cd /usr/bin

ln -s /opt/rrdtool-1.7.0/bin/rrdcached rrdcached
ln -s /opt/rrdtool-1.7.0/bin/rrdtool rrdtool
ln -s /opt/rrdtool-1.7.0/bin/rrdcreate rrdcreate
ln -s /opt/rrdtool-1.7.0/bin/rrdupdate rrdupdate
ln -s /opt/rrdtool-1.7.0/bin/rrdcgi rrdcgi

but you can also add the /opt/rrdtool-1.7.0/bin to the PATH

are you getting this invalid option – ‘version’ error when running validate.php?

====================================

Component Version
LibreNMS 1.44-20-g7a2c9d9
DB Schema 269
PHP 7.2.10
MySQL 5.5.60-MariaDB
RRDTool 1.7.0

SNMP | NET-SNMP 5.7.2

====================================

[OK] Composer Version: 1.7.2
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct
invalid option – 'version’

Hi. I thought I set up the new RRDTool without issue but now its not drawing graphs at all. Has this happened to you?

Nope, check the user owner and the permissions on the RRD destination dir; check in the logs if there is any write permission issue
Maybe you have misalignment between uid/gid from servers,pollers?