Webmin is a web-based control panel which is supported on many Linux distributions. Webmin is among the most popular open-source control panels – these are mostly used for user account management, web server administration, DNS configuration, FTP configuration, and much more. Webmin is an excellent and popular control panel all thanks to its extendability. Webmin is written in Perl and is open-source, making it free and kept up-to-date frequently. In this article, we will show you how to install Webmin on Ubuntu 18.04.
There are two methods for installing the Webmin control panel on Debian-based distributions. In this article, we will cover both of them.
1. Log in via SSH on the Ubuntu server:
Log in via SSH to the server as the root user (or as a user with sudo privileges):
ssh [email protected]er_IP_Address -p Port_number
2. Update all Packages
The first thing to do once you are logged in is to make sure that all of the installed OS packages are up to date:
sudo apt update sudo apt upgrade
3. Webmin Installation from a Package (Method 1)
With this method, we will install Webmin by using the Debian package -this is suitable for Debian, Ubuntu, or other Debian-based Linux distributions.
We will use the wget command to download the Webmin package:
Once this is done, we then have to install several dependencies:
sudo apt install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl apt-show-versions python
After downloading the Webmin package and after all dependencies are properly installed, we can continue installing Webmin with the following command:
sudo dpkg --install webmin_1.900_all.deb
Webmin will automatically be installed in the /usr/share/webmin directory, and by default, the installation will set an administrator username and password.
4. Using the Webmin APT Repository (Method 2)
With this method, we will use the Webmin APT repository to install the Webmin control panel.
First, we need to add the Webmin repository. Open the /etc/apt/sources.list with your favorite editor (in this example we will use nano):
sudo nano /etc/apt/sources.list
Add the following line to the end of the file:
deb https://download.webmin.com/download/repository sarge contrib
With the following commands, we will fetch and install the GPG key with which the repository is signed:
cd /root wget http://www.webmin.com/jcameron-key.asc sudo apt-key add jcameron-key.asc
Now we can install Webmin with these commands:
sudo apt install apt-transport-https sudo apt update sudo apt install webmin
With this method, unlike the previous one, all dependencies should be resolved automatically.
5. Accessing Webmin
The default port on which the Webmin service listens is port 10000. With this info, you can open your favorite browser web browser, type your server IP address followed by :10000, and you should be able to see the ‘Login to Webmin interface’ message. The full URL would be in this format:
Make sure to replace the “server_IP_Address” in the URL with your actual server IP address. It’s likely that when you access Webmin like this, your browser will output a message about the connection being insecure.
You can ignore the warning, accept the self-signed SSL certificate provided by the control panel, and proceed to the login screen. Or, you can install an SSL certificate for a domain hosted on your server, and access Webmin using “
https://yourdomain.com:10000“. You can use root as a username with your root password, or as any user who can use sudo.
6. Configure Webmin
In this part of the article, we will show you how to change the Webmin port in the Webmin configuration.
We can edit the miniserv.conf file to change the default Webmin port from 10000 to any port of our choice. With the following command, we will open the configuration file:
sudo nano /etc/webmin/miniserv.conf
Then find the following line:
and change the default port. In our example, we will change it to 8989:
Save the file and exit the editor.
Or, we can add a firewall rule (if you are using any firewall on your server) and change the default Webmin port. If you are using Iptables or UFW as a firewall, you can allow the incoming traffic from any source to TCP port 8989 by using the following commands:
iptables -A INPUT -p tcp -m tcp --dport 8989 -j ACCEPT
and for UFW (Ubuntu firewall):
sudo ufw allow from any to any port 8989 proto tcp
7. Uninstall Webmin
If for some reason you do not find Webmin suitable for your needs, you can always uninstall it. In order to remove the Webmin package, you will need to execute the following command:
sudo apt --purge remove webmin
This will stop and remove the Webmin files and configurations.
If you followed the steps in the tutorial, you will have successfully installed Webmin on your Ubuntu 18.04 VPS. For more details about its configuration and usage, please check the Webmin official documentation.
Of course, you don’t have to install Webmin on Ubuntu 18.04 if you use one of our Webmin Hosting Services, in which case you can simply ask our expert system administrators to install Webmin on Ubuntu 18.04 for you. They are available 24×7 and will take care of your request immediately.
PS. If you liked this post on how to install Webmin on Ubuntu 18.04, please share it with your friends on the social networks using the buttons below, or simply leave a comment in the comments section. Thanks.