I have a distributed environment composed of 2 servers: A server with all the elements, to be used as a WebUI/DB/RRD server and another one to be used only as a poller.
This is how the config.php looks like:
Server 1:
### Database config
$config['db_host'] = 'localhost';
$config['db_port'] = '3306';
$config['db_user'] = 'librenms';
$config['db_pass'] = 'password';
$config['db_name'] = 'librenms';
$config['db_socket'] = '/database/mariadb/mysql/mysql.sock';
// Distributed Poller-Settings
$config['distributed_poller'] = true;
// optional: defaults to hostname
$config['distributed_poller_name'] = 'server1';
$config['distributed_poller_group'] = 0;
$config['distributed_poller_memcached_host'] = '10.0.0.51';
$config['distributed_poller_memcached_port'] = '11211';
// This is the user LibreNMS will run ad
//Please ensure this user is created and has the correct permissions to your install
$config['user'] = 'librenms';
$config['rrdtool'] = '/database/rrdtool-1.7.2/bin/rrdtool';
$config['rrdtool_version'] = '1.7.2';
$config['rrd_dir'] = '/database/rrdtool-1.7.2/libredata';
$config['rrdcached'] = 'server1:42217';
# $config['rrdcached'] = "unix:/database/rrdtool-1.7.2/rrdcached.sock";
Server 2:
// Distributed Poller-Settings
$config['distributed_poller'] = true;
// optional: defaults to hostname
$config['distributed_poller_name'] = 'server2';
$config['distributed_poller_group'] = 1;
$config['distributed_poller_memcached_host'] = '10.0.0.51';
$config['distributed_poller_memcached_port'] = '11211';
// This is the user LibreNMS will run ad
//Please ensure this user is created and has the correct permissions to your install
$config['user'] = 'librenms';
$config['rrdcached'] = "10.0.0.51:42217";
$config['rrdtool'] = '/database/rrdtool-1.7.2/bin/rrdtool';
$config['db_host'] = 'server1';
$config['db_port'] = '3306';
$config['db_user'] = 'librenms';
$config['db_pass'] = 'password';
$config['db_name'] = 'librenms';
Is this enough information for Libre to understand that this is a distributed setup?
Validate looks good on both:
Server1:
sh: line 1: 117976 Killed sudo -K > /dev/null 2>&1
sh: line 1: 117994 Killed sudo -K > /dev/null 2>&1
====================================
Component | Version
--------- | -------
LibreNMS | 1.67-11-g114df5aa8
DB Schema | 2020_08_28_212054_drop_uptime_column_outages (173)
PHP | 7.2.33
Python | 3.6.8
MySQL | 5.5.65-MariaDB
RRDTool | 1.7.2
SNMP | NET-SNMP 5.7.2
====================================
[OK] Composer Version: 1.10.12
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct
[WARN] IPv6 is disabled on your server, you will not be able to add IPv6 devices.
Server2:
sh: line 1: 28831 Killed sudo -K > /dev/null 2>&1
sh: line 1: 28844 Killed sudo -K > /dev/null 2>&1
====================================
Component | Version
--------- | -------
LibreNMS | 1.67-11-g114df5aa8
DB Schema | 2020_08_28_212054_drop_uptime_column_outages (173)
PHP | 7.3.22
Python | 3.6.8
MySQL | 5.5.65-MariaDB
RRDTool | 1.7.2
SNMP | NET-SNMP 5.7.2
====================================
[OK] Composer Version: 1.10.12
[OK] Dependencies up-to-date.
[OK] Database connection successful
[OK] Database schema correct
[WARN] IPv6 is disabled on your server, you will not be able to add IPv6 devices.