System Adminstration in Linux constantly requires a Linux admin or user to spend copious amounts of time on the terminal running commands. Over time, however, running commands on a dark console can induce some boredom, and a graphical alternative can bring much relief.
Webmin is an open-source and easy-to-use web-based Linux administration tool that allows sysadmins to easily configure the Linux systems remotely via a web browser. It provides an intuitive dashboard with real-time monitoring of integral metrics such as CPU and RAM. Additionally, you can perform basic sysadmin tasks such as user account management, package management, configuring the firewall, and creating cron jobs to mention a few.
In this guide, we walk you through the installation of Webmin on Rocky Linux 8.
As you get started out, here is what you need:
- An instance of Rocky Linux 8
- Apache webserver installed. Check out our article on how to install LAMP on Rocky Linux 8.
- A sudo user configured on the instance
There are several ways of installing Webmin: You can download and run the RPM package, you can install from the repository or better yet, install Webmin from an automated installer script. Installation from the installation script is the most preferred way since it gives you the latest package. Also, it automates the creation of custom directories and the creation of the admin user and password.
In this guide, we will install Webmin using the installation script on Rocky Linux.
Step 1: Download the Webmin archive file
Webmin’s download page offers an array of binary package formats that you can download; from RPM to Deb packages for Debian-based distributions. We are going to download the compressed tarball file which contains the installation script.
To achieve this, download it as follows.
$ wget https://prdownloads.sourceforge.net/webadmin/webmin-1.979.tar.gz
You can verify the download using the ls command.
$ ls -l | grep webmin
You can verify the authenticity of the download using MD5 verification
$ md5sum webmin-1.979.tar.gz
This will display the MD5 checksum directly below.
The checksum should correspond to the checksum on the download site as indicated. As you can see, the checksum values from the terminal correspond to the one on the site.
Step 2: Extract the Webmin archive
Moving on. We are going to extract the Webmin’s archive using the tar command as shown.
$ tar -xvf webmin-1.979.tar.gz
This decompressed all the contents of the compressed file into a Webmin directory.. You use the ls command to verify its existence.
$ ls -l | grep webmin
Step 3: Install Webmin from the installation script
Up until this point, we have all the required files needed for the installation of Webmin. The next course of action is to create a Webmin directory in the /usr/local/ path which is the directory used to store applications locally by sysadmins.
$ sudo mkdir -p /usr/local/webmin
Next, run the installation script against the newly-created directory.
$ sudo ./webmin-1.979/setup.sh /usr/local/webmin
The script will set off a series of prompts. For simplicity, accept the defaults by pressing ENTER as shown.
Create an Administrator by providing the login name and password. Be sure to also use SSL for purposes for the sole purpose of providing encryption on the webmin site.
The script will run a couple of tasks and this takes a while – approximately 10 minutes. Finally, if all went well, Webmin will be installed successfully and the URL with which you can login with will be provided. By default, Webmin listens to port 10000.
Step 4: Configure the firewall to allow access to Webmin
Since Webmin will mostly be accessed remotely, it’s important to allow access to it to external users. Therefore, be sure to open port 10000 as shown.
$ sudo firewall-cmd --add-port=10000/tcp --permanent
Then reload the firewall to apply the changes that you’ve just made.
$ sudo firewall-cmd --reload
Step 5: Access Webmin
To access Webmin, browser the URL indicated.
https://server-IP or FQDN:10000
Initially, you will get an alert of an impending security risk if you continue browsing. But don;t worry, this is simply because we chose to encrypt Webmin with an SSL certificate which is not recognized by CA – Certificate Authority.
To get around this, click on the ‘Advanced’ button.
Hit the ‘Accept the Risk and Continue’ button to move on to the login page.
On the Login page, key in the admin username and password and chit the ‘Sign In’ button.
The Webmin dashboard will come to view. At a glance, you can view crucial metrics such as CPU, RAM and Disk utilization and other details such as hostname, OS version, time and date, Uptime , kernel and CPU version to mention a few.
Scrolling down reveals some real-time stats of metrics such as Memory, CPU, Swap and disk I/O in a graph format.
On the left sidebar are additional options that you can look around and configure.
And that’s it. We have successfully installed Webmin on Rocky Linux 8 using the automated installation script.
Karim Buzdar holds a degree in telecommunication engineering and holds several sysadmin certifications including CCNA RS, SCP, and ACE. As an IT engineer and technical author, he writes for various websites.