In this tutorial we will go through the steps to install Nagios XI on Rocky Linux 9. But before we do that, let me give some brief overview. Nagios XI is enterprise network monitoring software built on the powerful technology of Nagios Core. Nagios XI offers different enterprise features than Nagios Core.
How Nagios XI is different from Nagios Core?
In general, the differences are:
- Nagios users need technical and command line knowledge. Nagios XI, on the other hand, eliminates the need for users to understand command line code with a user-friendly interface designed for non-technical users.
- To monitor a device in Nagios Core, the user must not only understand the Linux command line, but also be very familiar with the setup of the Nagios Core interface.Nagios XI is easier to set up and use than Nagios. Nagios XI's robust, intuitive web interface makes it easy for non-technical users to access the information they need.
- Nagios XI assists enterprise customers who routinely need to report data, provide information, and verify the cost of additional resources (employees, hardware etc).Nagios Core is for technical output only.
- The enterprise edition of Nagios XI has additional tools that distinguish it from Nagios Core, in addition to the features that come with a standard license. For example:
- Capacity Planning
- Batch Modification
- Scheduled Reports and Pages
Different Methods to Install Nagios XI
We will use Rocky Linux 9, a Redhat-based operating system, for installation and we will install Nagios XI in two methods.
Method -1- One Step Quick Install
This script needs to be run as root/superuser. Switch to root user with the following command:
[foc@rocky9 ~]$ sudo su We trust you have received the usual lecture from the local System Administrator. It usually boils down to these three things: #1) Respect the privacy of others. #2) Think before you type. #3) With great power comes great responsibility. [sudo] password for foc: [root@rocky9 foc]#
Install the package dependencies that the install script will need (From base repo):
[root@rocky9 foc]# dnf install tar wget
Install the package dependencies that will be needed from the CRB repository:
[root@rocky9 foc]# dnf --enablerepo=crb install mysql-devel python3-rrdtool perl-Params-Validate
Finally, run the command that will download the installation script and start the installation. Installation will be completed in 15-20 minutes.:
[root@rocky9 foc]# curl https://assets.nagios.com/downloads/nagiosxi/install.sh | sh % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 629 100 629 0 0 781 0 --:--:-- --:--:-- --:--:-- 780 check if /tmp/nagiosxi exists Downloading latest Nagios XI release --2022-09-14 14:03:36-- https://assets.nagios.com/downloads/nagiosxi/xi-latest.tar.gz Resolving assets.nagios.com (assets.nagios.com)... 45.79.49.120, 2600:3c00::f03c:92ff:fef7:45ce Connecting to assets.nagios.com (assets.nagios.com)|45.79.49.120|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 80933313 (77M) [application/x-gzip] Saving to: ‘/tmp/xi-latest.tar.gz’ /tmp/xi-latest.tar.gz 100%[===============================================>] 77.18M 2.10MB/s in 43s 2022-09-14 14:04:20 (1.79 MB/s) - ‘/tmp/xi-latest.tar.gz’ saved [80933313/80933313] Checking MySQL credentials... MySQL not yet installed - that's okay. Running './0-repos'... Configuring Repos... package centos-stream-release is not installed Enabling Nagios repo... Installing Nagios Repo PKG: packages/nagios-repo-9-latest.el9.noarch.rpm Verifying... ######################################## Preparing... ######################################## Updating / installing... nagios-repo-9-1.el9 ######################################## Nagios 2.1 kB/s | 2.7 kB 00:01 Nagios XI Dependencies 1.2 kB/s | 1.5 kB 00:01 Install 588 Packages Upgrade 4 Packages Total size: 344 M Total download size: 344 M Downloading Packages: (1/591): fping-5.0-4.el9.x86_64.rpm 119 kB/s | 38 kB 00:00 (2/591): freetds-devel-1.3.3-1.el9.x86_64.rpm 403 kB/s | 47 kB 00:00 (3/591): freetds-1.3.3-1.el9.x86_64.rpm 545 kB/s | 273 kB 00:00 (4/591): libmcrypt-2.5.8-30.el9.x86_64.rpm 979 kB/s | 105 kB 00:00 (5/591): freetds-libs-1.3.3-1.el9.x86_64.rpm 1.9 MB/s | 426 kB 00:00 (6/591): libmcrypt-devel-2.5.8-30.el9.x86_64.rp 190 kB/s | 15 kB 00:00 ... Verifying configuration with Nagios Core > Output: Nagios Core 4.4.7 Copyright (c) 2009-present Nagios Core Development Team and Community Contributors Copyright (c) 1999-2009 Ethan Galstad Last Modified: 2022-04-14 License: GPL Website: https://www.nagios.org Reading configuration data... Read main config file okay... Read object config files okay... Running pre-flight check on configuration data... Checking objects... Checked 12 services. Checked 1 hosts. Checked 1 host groups. Checked 0 service groups. Checked 1 contacts. Checked 2 contact groups. Checked 138 commands. Checked 8 time periods. Checked 0 host escalations. Checked 0 service escalations. Checking for circular paths... Checked 1 hosts Checked 0 service dependencies Checked 0 host dependencies Checked 8 timeperiods Checking global event handlers... Checking obsessive compulsive processor commands... Checking misc settings... Total Warnings: 0 Total Errors: 0 Things look okay - No serious problems were detected during the pre-flight check > Return Code: 0 -------------------------------------- CCM data imported OK. RESULT=0 Running './F-startdaemons'... Daemons started OK RESULT=0 Running './Z-webroot'... RESULT=0 Nagios XI Installation Complete! -------------------------------- You can access the Nagios XI web interface by visiting: http://192.168.0.171/nagiosxi/
Installation completed successfully. You have also got the IP to be used to access the Nagios GUI in the installation output. Continue by typing http://192.168.0.171/nagiosxi/
into the web browser.
Specify general system settings and license information.
Next update the password for the nagiosadmin
user:
In the next screen you will get link to login to Nagios XI along with your credentials
Continue to login with these credentials, Accept the License Agreement and you will get access to the Nagios XI dashboard
Nagios XI, latest version xi-5.9.1 installation and initial configuration is complete.
Method -2- Manual Installation of Custom Nagios Version
We installed xi-5.9.1 in the first method. In this method, let's install the xi-5.9.0 version. Go to Nagios XI versions list. (If you want a different version, right click on the version you want to install and get the link). Link for the version xi-5.9.0 we will install: https://assets.nagios.com/downloads/nagiosxi/5/xi-5.9.0.tar.gz
Then follow the below steps in terminal using this link:
[foc@rocky9 ~]$ sudo su
[root@rocky9 foc]# cd /tmp/
[root@rocky9 tmp]# dnf install tar wget
[root@rocky9 tmp]# dnf --enablerepo=crb install mysql-devel python3-rrdtool perl-Params-Validate
[root@rocky9 tmp]# wget https://assets.nagios.com/downloads/nagiosxi/5/xi-5.9.0.tar.gz
--2022-09-14 15:04:14-- https://assets.nagios.com/downloads/nagiosxi/5/xi-5.9.0.tar.gz
Resolving assets.nagios.com (assets.nagios.com)... 45.79.49.120, 2600:3c00::f03c:92ff:fef7:45ce
Connecting to assets.nagios.com (assets.nagios.com)|45.79.49.120|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 80934747 (77M) [application/x-gzip]
Saving to: ‘xi-5.9.0.tar.gz’
xi-5.9.0.tar.gz 100%[===============================================>] 77.18M 1.88MB/s in 42s
2022-09-14 15:04:56 (1.85 MB/s) - ‘xi-5.9.0.tar.gz’ saved [80934747/80934747]
[root@rocky9 tmp]# tar xzf xi-5.9.0.tar.gz
[root@rocky9 tmp]# cd nagiosxi/
Let's start the installation:
[root@rocky9 nagiosxi]# ./fullinstall
========================
Nagios XI Full Installer
========================
This script will do a complete install of Nagios XI by executing all necessary sub-scripts.
IMPORTANT: This script should only be used on a 'clean' install of CentOS, RHEL, Ubuntu LTS, Debian, or Oracle. Do
NOT use this on a system that has been tasked with other purposes or has an existing install of Nagios Core. To
create such a clean install you should have selected only the base package in the OS installer.
Do you want to continue? [Y/n] Y
...
Nagios XI Installation Complete!
--------------------------------
You can access the Nagios XI web interface by visiting:
http://192.168.122.238/nagiosxi/
Go to http://192.168.122.238/nagiosxi/
with a web browser and complete the following steps:
- General System Settings
- License Settings
- Admin Account Settings
- Admin Notification Settings
Successfully installed version xi-5.9.0 for Nagios XI.
Summary
To learn the details of the differences between the Nagios XI and the Nagios, visit the news page. If you want to install a specific version of Nagios XI, be sure to visit the Nagios XI release page. In this article, we tried to explain the installation of Nagios XI on Rocky Linux 9. You can also perform a clean install by following the steps above.
References
Nagios.com - Installing Nagios XI Manually on Linux