
How to Install Webmin on Ubuntu 20.04: A Step-by-Step Guide
Managing a Linux server from the command line is powerful, but it can be intimidating and time-consuming. For system administrators looking for a more efficient and visual way to handle server tasks, Webmin is a leading solution. This powerful, web-based control panel simplifies everything from user account management to configuring complex services like Apache and DNS.
This comprehensive guide will walk you through the process of installing and securing Webmin on your Ubuntu 20.04 server, giving you a robust tool to streamline your system administration workflow.
Prerequisites
Before we begin, ensure you have the following in place:
- An Ubuntu 20.04 server.
- A user account with
sudo
or root privileges. - A firewall configured on your server. We will use UFW (Uncomplicated Firewall) in this guide.
Step 1: Update Your System and Install Dependencies
First, it’s always best practice to ensure your system’s package list and installed packages are up to date. This helps prevent conflicts and ensures you have the latest security patches.
Open your terminal and run the following commands:
sudo apt update
sudo apt upgrade
Next, we need to install a few packages that are required for adding and managing third-party repositories, which is how we will install Webmin.
sudo apt install software-properties-common apt-transport-https wget
Step 2: Add the Webmin Repository
Webmin is not included in the default Ubuntu repositories. To install it, we must add the official Webmin repository to our system’s sources list. This ensures we can easily install and receive future updates through the standard apt
package manager.
First, import the Webmin PGP key. This key is used to verify that the packages you are downloading are authentic and have not been tampered with.
wget -q http://www.webmin.com/jcameron-key.asc -O- | sudo apt-key add -
With the key imported, you can now add the repository to your system’s software sources:
sudo add-apt-repository "deb [arch=amd64] http://download.webmin.com/download/repository sarge contrib"
Step 3: Install Webmin
Now that the Webmin repository is successfully added, we need to update the package list one more time to include the packages available from it.
sudo apt update
Finally, you can install Webmin with a single command:
sudo apt install webmin
Once the installation completes, the Webmin service will start automatically. You can verify that it is running correctly with the following command:
sudo systemctl status webmin
You should see output indicating the service is active (running). If it isn’t, you can start it manually with sudo systemctl start webmin
.
Step 4: Configure Your Firewall for Webmin Access
For security, your server should be protected by a firewall. By default, Webmin listens for connections on port 10000. We must open this port in the firewall to allow access to the Webmin web interface.
If you are using UFW, you can allow traffic on this port by running:
sudo ufw allow 10000/tcp
After adding the rule, you can check the status of your firewall to confirm the change:
sudo ufw status
The output should show that connections are allowed on port 10000. This is a critical security measure; without it, you will not be able to connect to the Webmin dashboard.
Step 5: Access the Webmin Dashboard
With the installation and firewall configuration complete, you are ready to access your Webmin dashboard.
Open your favorite web browser and navigate to your server’s IP address or domain name, followed by the port number 10000
. Be sure to use HTTPS.
https://your_server_ip:10000
Your browser will likely display a security warning stating that the SSL certificate is not trusted. This is expected because Webmin automatically generates a self-signed certificate for secure communication. It is safe to proceed. Click “Advanced” and choose to continue to the site.
You will be presented with a login screen. To log in, use a user account that has sudo
or root privileges on your Ubuntu server.
Once you log in, you will be greeted by the Webmin dashboard. This interface provides a comprehensive overview of your server’s resources, including CPU usage, memory, and disk space. From here, you can explore the left-hand menu to manage nearly every aspect of your server, from software packages and running processes to network configurations and scheduled cron jobs.
You now have a powerful web-based interface to manage your Ubuntu 20.04 server, making complex administrative tasks simpler and more accessible.
Source: https://kifarunix.com/install-webmin-on-ubuntu-20-04/