How to Install Observium on Debian Latest

Observium is a network monitoring tool that allows network administrators to monitor various devices and services on their networks. It provides detailed insights into the performance and status of network devices, which helps administrators to identify and resolve issues quickly.

This tutorial will guide you through the installation of Observium on Debian Latest using the official installation script.

Prerequisites

Before we start with the installation, you need to ensure the following prerequisites are met:

Once you have these prerequisites in place, you can proceed with the installation.

Step 1: Installing Required Packages

First, update the system package list by running the following command:

sudo apt update

Next, install the required packages for Observium by running this command:

sudo apt install apache2 libapache2-mod-php mariadb-server mariadb-client php \
php-cli php-common php-curl php-mysql php-gd php-json php-snmp \
php-mbstring snmp graphviz graphviz-dev libapache2-mod-security2 \
composer fping imagemagick whois mtr-tiny nmap python-memcache \
python-mysqldb python-psycopg2 rrdtool git unzip curl wget

Step 2: Installing Observium

After installing the required packages, we can proceed with the installation of Observium.

First, clone the Observium repository from GitHub by running the following command:

sudo git clone https://github.com/observium/observium.git /opt/observium

Next, navigate to the Observium directory by running the command:

cd /opt/observium

Then, you can install Observium by running the following command:

sudo ./discovery.php -u

Step 3: Configuring Apache

Observium uses Apache as its web server. We need to configure Apache to serve Observium by creating a virtual host file.

First, create a virtual host file in the Apache sites-available directory by running this command:

sudo nano /etc/apache2/sites-available/observium.conf

Add the following code to the file:

<VirtualHost *:80>

  DocumentRoot /opt/observium/html/

  <Directory /opt/observium/html/>
    AllowOverride All
    Options FollowSymLinks MultiViews
    Require all granted
  </Directory>

  ErrorLog /var/log/apache2/observium_error.log
  CustomLog /var/log/apache2/observium_access.log combined

</VirtualHost>

Save and close the file.

After creating the virtual host file, enable it by running the following command:

sudo a2ensite observium.conf

Then, reload the Apache configuration by running:

sudo systemctl reload apache2

Step 4: Configuring MySQL

Observium uses MySQL as its database backend. We need to create a database and a user for Observium to connect to.

First, log in to the MySQL shell by running:

sudo mysql -u root -p

Then, create a database for Observium by running:

CREATE DATABASE observium;

Next, create a MySQL user for Observium by running:

CREATE USER 'observium'@'localhost' IDENTIFIED BY 'password';

Make sure to replace password with a secure password.

After creating the database and user, grant the user privileges to the Observium database by running:

GRANT ALL PRIVILEGES ON observium.* TO 'observium'@'localhost' IDENTIFIED BY 'password';

Finally, exit the MySQL shell by running:

exit

Step 5: Configuring Observium

Now that we have installed Observium and configured Apache and MySQL, we can proceed with configuring Observium itself.

Navigate to the Observium configuration directory by running:

cd /opt/observium/

Then, copy the sample configuration file by running:

sudo cp config.php.default config.php

Next, edit the configuration file with your favorite text editor:

sudo nano config.php

Change the following lines to reflect your MySQL credentials:

$config['db_host']         = 'localhost';
$config['db_user']         = 'observium';
$config['db_pass']         = 'password';
$config['db_name']         = 'observium';

Save and close the file.

Step 6: Starting Observium

After configuring Observium, we can start the Observium service by running the following commands:

sudo systemctl enable observium
sudo systemctl start observium

Step 7: Accessing Observium

Observium is now installed and running. You can access the Observium web interface by navigating to http:/// in a web browser.

When prompted for login credentials, enter admin as both the username and password.

Congratulations, you have successfully installed Observium on Debian Latest!

Conclusion

In this tutorial, we went through the steps required to install Observium on Debian Latest. After installation, we configured Apache, MySQL, and Observium itself, and started the Observium service.

Observium is a powerful monitoring tool that can help network administrators to gain valuable insights into their network performance and status. If you encounter any issues during the installation process or when using Observium, refer to the official Observium documentation for troubleshooting guidance.

If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!

Alternatively, for the best virtual desktop, try Shells!