Installing on Ubuntu 18

Following the official documentation I used the command below but it seems a lot of these packages are not available on Ubuntu 18. I figured a lot of people would have had this same issue but when I searched I didn’t find anything. Are these packages actually required to run LibreNMS? And if so, how should I proceed on Ubuntu 18?

sudo apt install curl apache2 composer fping git graphviz imagemagick libapache2-mod-php7.2 mariadbclient mariadb-server mtr-tiny nmap php7.2-cli php7.2-curl php7.2-gd php7.2-json php7.2-mbstring php7.2- mysql php7.2-snmp php7.2-xml php7.2-zip python-memcache python-mysqldb rrdtool snmp snmpd whois . 
[sudo] password for user:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package graphviz is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Unable to locate package composer
E: Unable to locate package fping
E: Package 'graphviz' has no installation candidate
E: Unable to locate package mariadb-client
E: Unable to locate package mariadb-server
E: Unable to locate package php7.2-mbstring
E: Couldn't find any package by glob 'php7.2-mbstring'
E: Couldn't find any package by regex 'php7.2-mbstring'
E: Unable to locate package php7.2-zip
E: Couldn't find any package by glob 'php7.2-zip'
E: Couldn't find any package by regex 'php7.2-zip'

Copy and pasting the command from the docs:

sudo apt install curl apache2 composer fping git graphviz imagemagick libapache2-mod-php7.2 mariadb-client mariadb-server mtr-tiny nmap php7.2-cli php7.2-curl php7.2-gd php7.2-json php7.2-mbstring php7.2-mysql php7.2-snmp php7.2-xml php7.2-zip python-memcache python-mysqldb rrdtool snmp snmpd whois
Reading package lists... Done
Building dependency tree
Reading state information... Done
mtr-tiny is already the newest version (0.92-1).
nmap is already the newest version (7.60-1ubuntu5).
python-memcache is already the newest version (1.57-2).
python-mysqldb is already the newest version (1.3.10-1build1).
rrdtool is already the newest version (1.7.0-1build1).
snmp is already the newest version (5.7.3+dfsg-1.8ubuntu3).
snmpd is already the newest version (5.7.3+dfsg-1.8ubuntu3).
whois is already the newest version (5.3.0).
composer is already the newest version (1.6.3-1).
fping is already the newest version (4.0-6).
graphviz is already the newest version (2.40.1-2).
apache2 is already the newest version (2.4.29-1ubuntu4.2).
curl is already the newest version (7.58.0-2ubuntu3.2).
git is already the newest version (1:2.17.1-1ubuntu0.1).
imagemagick is already the newest version (8:6.9.7.4+dfsg-16ubuntu6.3).
libapache2-mod-php7.2 is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-cli is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-curl is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-gd is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-json is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-mysql is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-snmp is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-xml is already the newest version (7.2.7-0ubuntu0.18.04.2).
mariadb-client is already the newest version (1:10.1.34-0ubuntu0.18.04.1).
mariadb-server is already the newest version (1:10.1.34-0ubuntu0.18.04.1).
php7.2-mbstring is already the newest version (7.2.7-0ubuntu0.18.04.2).
php7.2-zip is already the newest version (7.2.7-0ubuntu0.18.04.2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Did you run apt update first?

1 Like

Yes. Maybe there is something wrong with my Ubuntu installation? I also ran sudo apt-get upgrade and it ran fine.

sudo apt update
Hit:1 http://archive.ubuntu.com/ubuntu bionic InRelease
Get:2 http://archive.ubuntu.com/ubuntu bionic-security InRelease [83.2 kB]
Hit:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
Fetched 83.2 kB in 1s (109 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.

Make sure you sent the right command. You have it wrong in your initial post here…

When are you using an ubuntu 18 for the first time you need to enable repositories with

sudo add-apt-repository universe
sudo add-apt-repository multiverse

then you can install packages