Installation and Configuration

Objectives

  • Installing all required OpenNMS Meridian components including PostgreSQL on a single node

  • Meridian Core and PostgreSQL run with the default configuration which are not optimized for running in production and monitoring large networks

  • As a result you will have RRDtool as time series storage which persists RRD files on the local file system and is the default

  • Login to the web user interface and change the default admin password

Requirements

  • Linux physical server or a virtual machine running a supported Linux operating system

  • Internet access to download the installation packages

  • Make sure DNS is working and localhost and your servers host name is resolved properly

  • System user with administrative permissions (sudo) to perform the installation tasks

Setting up PostgreSQL

  • CentOS/RHEL 8

  • CentOS/RHEL 7

Install PostgreSQL client and server
sudo dnf -y install postgresql-server postgresql
Initialization of the PostgreSQL database
sudo postgresql-setup --initdb --unit postgresql
Enable PostgreSQL on system boot and start immediately
sudo systemctl enable --now postgresql
Create an opennms database user with a password
sudo -i -u postgres createuser -P opennms
You get asked for a password for the database user opennms. This guide uses YOUR-OPENNMS-PASSWORD as a placeholder and please set a secure password.
Create an empty database and set the owner to the opennms user
sudo -i -u postgres createdb -O opennms opennms
Set a password for Postgres super user
sudo -i -u postgres psql -c "ALTER USER postgres WITH PASSWORD 'YOUR-POSTGRES-PASSWORD';"
Change YOUR-POSTGRES-PASSWORD to a secure one. The super user is required to be able to initialize and change the database schema for installation and updates.
Change the access policy for PostgreSQL
sudo vi /var/lib/pgsql/data/pg_hba.conf
Allow Meridian accessing the database over the local network with a MD5 hashed password
host    all             all             127.0.0.1/32            md5(1)
host    all             all             ::1/128                 md5(1)
1 Change method from ident to md5 for IPv4 and IPv6 on localhost.
Apply configuration changes for PostgreSQL
sudo systemctl reload postgresql
Add PostgreSQL 12 package repository
sudo yum -y install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
Install PostgreSQL 12 client and server
sudo yum -y install postgresql12-server postgresql12
Initialization of the PostgreSQL database
sudo /usr/pgsql-12/bin/postgresql-12-setup initdb
Enable PostgreSQL on system boot and start immediately
sudo systemctl enable --now postgresql-12
Create an opennms database user with a password
sudo -i -u postgres createuser -P opennms
You get asked for a password for the database user opennms. This guide uses YOUR-OPENNMS-PASSWORD as a placeholder and please set a secure password.
Create an empty database and set the owner to the opennms user
sudo -i -u postgres createdb -O opennms opennms
Set a password for Postgres super user
sudo -i -u postgres psql -c "ALTER USER postgres WITH PASSWORD 'YOUR-POSTGRES-PASSWORD';"
Change YOUR-POSTGRES-PASSWORD to a secure one. The super user is required to be able to initialize and change the database schema for installation and updates.
Change the access policy for PostgreSQL
sudo vi /var/lib/pgsql/12/data/pg_hba.conf
Allow Meridian accessing the database over the local network with a MD5 hashed password
host    all             all             127.0.0.1/32            md5(1)
host    all             all             ::1/128                 md5(1)
1 Change method from ident to md5 for IPv4 and IPv6 on localhost.
Apply configuration changes for PostgreSQL
sudo systemctl reload postgresql-12

Installing the Core Instance

  • CentOS/RHEL 8

  • CentOS/RHEL 7

Add repository and import GPG key
sudo dnf -y install https://yum.opennms.org/repofiles/opennms-repo-stable-rhel8.noarch.rpm
sudo rpm --import https://yum.opennms.org/OPENNMS-GPG-KEY
Installation of Meridian with all built-in dependencies
sudo dnf -y install opennms
This is optional, if you want time series trending and forecast functions you have to install the R project packages. The additional download size for packages is ~390 MB.
Installing R package for trending and forcasting
sudo dnf -y install epel-release
sudo dnf -y install R-core
We recommend disabling the OpenNMS Meridian repository after installation to prevent unwanted upgrades while it is running. Meridian requires some manual steps upon upgrade configuration files or migrate database schemas to a new version. For this reason, it is recommended to exclude the Meridian packages from update except when you are planning on performing an upgrade.
Disable auto updates for OpenNMS Meridian
sudo dnf config-manager --disable opennms-repo-stable-*
Verify directory structure with the tree command
sudo dnf -y install tree
tree /opt/opennms -L 1
Directory structure after successful installation
/opt/opennms
├── bin
├── contrib
├── data
├── deploy
├── etc
├── jetty-webapps
├── lib
├── logs -> /var/log/opennms
├── share -> /var/opennms
└── system
Add repository and import GPG key
sudo yum -y install https://yum.opennms.org/repofiles/opennms-repo-stable-rhel7.noarch.rpm
sudo rpm --import https://yum.opennms.org/OPENNMS-GPG-KEY
Installation of Meridian with all built-in dependencies
sudo yum -y install opennms
This is optional, if you want time series trending and forecast functions you have to install the R project packages. The additional download size for packages is ~220 MB.
Installing R package for trending and forcasting
sudo yum -y install epel-release
sudo yum -y install R-core
We recommend disabling the OpenNMS Meridian repository after installation to prevent unwanted upgrades while it is running. Meridian requires some manual steps upon upgrade configuration files or migrate database schemas to a new version. For this reason, it is recommended to exclude the Meridian packages from update except when you are planning on performing an upgrade.
Disable auto updates for OpenNMS Meridian
sudo yum -y install yum-utils
sudo yum-config-manager --disable opennms-repo-stable-*
Verify directory structure with the tree command
sudo yum -y install tree
tree /opt/opennms -L 1
Directory structure after successful installation
/opt/opennms
├── bin
├── contrib
├── data
├── deploy
├── etc
├── jetty-webapps
├── lib
├── logs -> /var/log/opennms
├── share -> /var/opennms
└── system

Setting up the Core Instance

  • CentOS/RHEL 7/8

Configure PostgreSQL database access
sudo vi /opt/opennms/etc/opennms-datasources.xml
Set credentials to access the PostgreSQL database
<jdbc-data-source name="opennms"
                    database-name="opennms"(1)
                    class-name="org.postgresql.Driver"
                    url="jdbc:postgresql://localhost:5432/opennms"
                    user-name="** YOUR-OPENNMS-USERNAME **"(2)
                    password="** YOUR-OPENNMS-PASSWORD **" />(3)

<jdbc-data-source name="opennms-admin"
                    database-name="template1"
                    class-name="org.postgresql.Driver"
                    url="jdbc:postgresql://localhost:5432/template1"
                    user-name="postgres"(4)
                    password="** YOUR-POSTGRES-PASSWORD **" />(5)
1 Set the database name Meridian should use
2 Set the user name to access the opennms database table
3 Set the password to access the opennms database table
4 Set the postgres user for administrative access to PostgreSQL
5 Set the password for administrative access to PostgreSQL
Detect and assign Java environment and persist in /opt/opennms/etc/java.conf
sudo /opt/opennms/bin/runjava -s
Initialize the database and detect system libraries persisted in /opt/opennms/etc/libraries.properties
sudo /opt/opennms/bin/install -dis
Enable Meridian core server on system boot and start immediately
sudo systemctl enable --now opennms
Allow connection to the Web UI from your network
sudo firewall-cmd --permanent --add-port=8980/tcp
sudo systemctl reload firewalld
If you want to receive SNMP Traps or Syslog messages you have to allow incoming traffic on your host firewall as well. By default OpenNMS Meridian SNMP trap daemon is listening on 162/udp and Syslog daemon is listening on 10514/udp. The SNMP Trap daemon is enabled by default, the OpenNMS Syslog daemon is disabled.

First Login

After starting the Meridian Core services the web application can be accessed on
http://core-instance-ip:8980/opennms. The default login user is admin and the password is initialized to admin.

Please change immediately the default password to a secure password.
  1. Open http://core-instance-ip:8980/opennms in your web browser

  2. Login with with admin/admin

  3. Click in main navigation menu on adminChange Password

  4. Use admin as the current password and set a new password and confirm with Submit

  5. Logout and login with your new password