Distributed Poller with Two Node

Hello,
I have two VM with librenms full setup configured and running with rrdcached. Now I want to enable distributed polling between them.

I have gone through the manual https://docs.librenms.org/Extensions/Distributed-Poller/

Following is the sample configuration

1st node

$config['distributed_poller_name']           = librenms-node1;
$config['distributed_poller_group']          = '0';
$config['distributed_poller_memcached_host'] = "librenms-node1";
$config['distributed_poller_memcached_port'] = 11211;
$config['distributed_poller']                = true;
$config['rrdcached']                         = "librenms-node1:42217";

Second node

$config['distributed_poller_name']           = librenms-node2;
$config['distributed_poller_group']          = '1';
$config['distributed_poller_memcached_host'] = "librenms-node2";
$config['distributed_poller_memcached_port'] = 11211;
$config['distributed_poller']                = true;
$config['rrdcached']                         = "librenms-node2:42217";

Can anyone please confirm whether anyone will this configuration work ?

Thanks in advance

I think both of your pollers should be pointing to the same rrdcached/memcached instance.

So assuming you have memcached and rrdcached running on the same host, you’ll want something like:

$config['distributed_poller_name']           = librenms-node1;
$config['distributed_poller_group']          = '0';
$config['distributed_poller_memcached_host'] = "HOSTNAME";
$config['distributed_poller_memcached_port'] = 11211;
$config['distributed_poller']                = true;
$config['rrdcached']                         = "HOSTNAME:42217";
$config['rrdtool_version'] = 'RRDTOOL_VERSION';

$config['distributed_poller_name']           = librenms-node2;
$config['distributed_poller_group']          = '1';
$config['distributed_poller_memcached_host'] = "HOSTNAME";
$config['distributed_poller_memcached_port'] = 11211;
$config['distributed_poller']                = true;
$config['rrdcached']                         = "HOSTNAME:42217";
$config['rrdtool_version'] = 'RRDTOOL_VERSION';

where HOSTNAME is the host of the machine running rrdcached/memcached and RRDTOOL_VERSION is the version of your rrdcached. You’ll also want your pollers to be pointing to the same MySQL instance as well. You can check /opt/librenms/.env on both pollers to see where that’s set.