librenms is a replacement to cacti, it is easier to configure, install and discovers your SNMP devices. before you begin, please ensure that your devices have snmp enabled and the rocommunity string is there, the default rocommunity string is normally set to public as its string.
ssh commands required
majority of the ssh commands requires nano or vim. my choice of a terminal editor would be nano. to find out more how to use nano, visit the following page to get the basics.
look out for notes
notes are placed in the guides, these markers requires your attention.
- 🗣 note: comments which you should take note of.
- ⚠️ important: comments which are important.
report inaccuracies and errors
if something in this guide is inaccurate, wrong, or outdated, report it by scanning the qr code.
- docker required
- phpmyadmin
- maridb and www (both installed when you install phpmyadmin)
⚠️ important: default login for phpmyadmin is username: root (there is no password) you will need to set a password for your root account.
ssh into your synology box with root access and execute the following commands
mkdir /volume1/docker/librenms/logs
mkdir /volume1/docker/librenms/rrd
next step is to login to your phpmyadmin and create the librenms database
in the phpmyadmin gui create a new db called librenms
click on the db and add a user to the librenms db. the username will be called librenms as well.
assign full rights to the db for user librenms
now ssh into your synology with root access and enter the following in sequence.
docker run \
-d \
-p 8668:80 \
-e DB_HOST=YOURSYNOLOGYIP \
-e DB_NAME=librenms \
-e DB_USER=librenms \
-e DB_PASS=YOURLIBRENMSUSERPASSWORD \
-e PUID=0 -e PGID=101 \
-e TZ=Asia/Singapore \
-e BASE_URL=http://YOURSYNOLOGYIP:8668 \
-e POLLERS=16 \
-v /volume1/docker/librenms/logs:/opt/librenms/logs \
-v /volume1/docker/librenms/rrd:/opt/librenms/rrd \
--name librenms \
jarischaefer/docker-librenms
now, librenms docker has been installed on your device
login to your synology gui and access docker.
activate the librenms container and click on details.
navigate to terminal > create > bash
run the following commands to inject the schema into the db
cd /opt/librenms/
php build-base.php
you should see the following output:
-- Updating database schema
000 -> 001 ... done.
001 -> 002 ... done.
002 -> 003 ... done.
003 -> 004 ... done.
004 -> 005 ... done.
005 -> 006 ... done (0 errors).
006 -> 007 ... done (0 errors).
...
144 -> 145 ... done (0 errors).
145 -> 146 ... done (0 errors).
-- Done
setting up the super account by entering the following in the librenms bash:
php adduser.php USERNAME PASSWORD 10 EMAIL@DOMAIN.COM
to wrap it up, execute this:
php validate.php
access your librenms and login at http://synology-ip:8668
🗣 note: one last thing to do is to have the timezone for docker’s VM synchronised to your synology’s timezone. To do so, execute the following in the librenms bash:
ln -sf /usr/share/zoneinfo/Asia/Singapore /etc/localtime this would ensure that the graphs plotted have the correct time displayed on them.
🗣 note: if you have issues adding devices, logon to your myphpadmin gui, access your librenms database, select all tables and drop the tables.
logon to Synology and access the bash for librenms and then run:
php /opt/librenms/build-base.php
if you’re facing errors with librenms and your mysql, where it states that the following error:
Access denied for user 'librenms'@'172.168.x.x' (using password: NO)
you will need to logon to your synology > docker > librenms > details > terminal > create > bash and execute the following:
vim /opt/librenms/config.php
followed by the changing of the db_pass to your mysql database password.
$config['db_pass'] = 'P@ssw0rd';
🗣 note: in the event that your docker container should get updated. There’s two possibilities to resolve it.
- reinstalling librenms container
- entering ENV information into the docker container
since the reinstall is already covered, we will attempt to input all the ENV settings into docker.
logon to your synology and check that the librenms container has not started.
click on the librenms > edit > environment
enter the following variables and values
variable value
DB_HOST SYNOLOGYIP
DB_NAME librenms
DB_USER librenms
DB_PASS MYSQLLIBRENMSPASSWORD
PUID 0
PGID 101
TZ Asia/Singapore
BASE_URL http://synologyip:8668
POLLER 16
save and exit and attempt to restart.