How to configure Network Monitoring using Observium (Centos 7)

To get you up and running with a Virtual Server please check out the following post:

Deploying a Virtual Machine on Piggybank’s cloud platform – The ultimate guide

1.Add Repositories

yum install
yum install
yum install

2.Install Prerequisites

yum install wget.x86_64 httpd.x86_64 php56w.x86_64 php56w-opcache.x86_64 php56w-mysql.x86_64 php56w-gd.x86_64 \
php56w-posix php56w-mcrypt.x86_64 php56w-pear.noarch cronie.x86_64 net-snmp.x86_64 \
net-snmp-utils.x86_64 fping.x86_64 mariadb-server.x86_64 mariadb.x86_64 MySQL-python.x86_64 \
rrdtool.x86_64 subversion.x86_64 jwhois.x86_64 ipmitool.x86_64 graphviz.x86_64 ImageMagick.x86_64

3.Download and install Observium

Create a directory for Observium

mkdir -p /opt/observium && cd /opt

Download Observium Community Edition

tar zxvf observium-community-latest.tar.gz

4. Create the MySQL database: (make sure you have [[Database/MySQL]] installed)

Start MySQL/MariaDB and configure it to be run at startup.

systemctl enable mariadb
systemctl start mariadb

Set the MySQL root password:

/usr/bin/mysqladmin -u root password ''

Create the MySQL database:

mysql -u root -p

mysql> CREATE DATABASE observium DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
mysql> GRANT ALL PRIVILEGES ON observium.* TO 'observium'@'localhost' IDENTIFIED BY '';
mysql> exit;

5.Configure Observium

cd observium
cp config.php.default config.php

Change the username and password in the following file to (SQL credentials) db_user & db_pass

nano config.php


Insert MySQL Schema

Run the discovery.php script with the upgrade switch -u in order to insert the initial MySQL schema

./discovery.php -u


Since Fping is in a different location, add a line to config.php to tell Observium.

$config['fping'] = "/sbin/fping";

6. Disable SELinux

Set SELINUX to permissive


7. System

Create the rrd directory to store RRDs in:

mkdir rrd
chown apache:apache rrd

If the server will be running only Observium, change /etc/httpd/conf.d/observium.conf and add the following to the end :

nano /etc/httpd/conf.d/observium.conf

DocumentRoot /opt/observium/html/
CustomLog /opt/observium/logs/access_log combined
ErrorLog /opt/observium/logs/error_log

AllowOverride All
Options FollowSymLinks MultiViews
Require all granted

8.Create logs directory for Apache

mkdir /opt/observium/logs
chown apache:apache /opt/observium/logs

9. Create first user login credentials (use level of 10 for admin)

cd /opt/observium

10. Add first device to monitor

Make sure that the intended monitored device (SNMP Client) is configured with the same community string and will allow SMNP queries from the SNMP manager (Observium).

./add_device.php   v2c

Do an initial discovery and polling run to populate the data for the new device:

./discovery.php -h all
./poller.php -h all

11. Add Cron Jobs

nano /etc/cron.d/observium

# Run a complete discovery of all devices once every 6 hours
33  */6   * * *   root    /opt/observium/discovery.php -h all >> /dev/null 2>&1

# Run automated discovery of newly added devices every 5 minutes
*/5 *     * * *   root    /opt/observium/discovery.php -h new >> /dev/null 2>&1

# Run multithreaded poller wrapper every 5 minutes
*/5 *     * * *   root    /opt/observium/ 8 >> /dev/null 2>&1

# Run housekeeping script daily for syslog, eventlog and alert log
13 5 * * * root /opt/observium/housekeeping.php -ysel

# Run housekeeping script daily for rrds, ports, orphaned entries in the database and performance data
47 4 * * * root /opt/observium/housekeeping.php -yrptb

Reload the cron process:

systemctl reload crond

12. Enable and start httpd

systemctl enable httpd
systemctl start httpd

This will ensure that httpd starts when we reboot the server

13. Test

(please note you will need a Public Address, Port Forwarding or Dialup VPN for access)

http://your_server_iP or http://your_domain_name