How to Install Webmin on Debian 12?


Webmin is a powerful as well as web-based control panel that permits users to manage several features of your Linux server (including Debian 12). Users can perform tasks like configuring DNS settings, managing user accounts, and adjusting settings for common packages. It is a useful interface for the system administration of Debian 12 servers. It allows users to manage several aspects of your server, such as users, services, packages, firewall, etc., through a simple and intuitive web browser.

This article will teach different methods to install Webmin on Debian 12 along with the configuration to access the Webmin interface.

Let’s start with the installation.

How to Install Webmin on Debian 12?

Webmin manages several aspects of your Debian 12 system. To Install Webmin on Debian 12, follow the below methods:

Let’s start with the easiest one.

Method 1: Install Webmin on Debian 12 from the Official Webmin Repository

Webmin is a web-based system administration tool to manage your system remotely and easily. To install Webmin on Debian 12 from the official repository, you need to follow these steps:

Step 1: Add Webmin Repository

Add the Webmin repository to your /etc/apt/sources.list file by running the following command as root:

echo "deb https://download.webmin.com/download/repository sarge contrib" | sudo tee -a /etc/apt/sources.list

Step 2: Download and Install the Webmin GPG Key

Now, users need to download and install the Webmin GPG key by running the below command:

wget -qO - https://download.webmin.com/jcameron-key.asc | sudo apt-key add -

Step 3: Update Package Lists

Now, user need to ensure that the package lists are updated via the below command:

sudo apt update

Step 4: Install Webmin

Now, install Webmin by running the “apt” command as root:

sudo apt install webmin

Step 5: Access Webmin Web Interface

Once the installation is done, access the web interface by visiting https://your-server-ip:10000 on the browser. It requires logging in with the root or sudo user credentials:

It navigates to the Webmin interface by pressing the “Sign in” button as below:

In this way, users can enjoy managing the Debian 12 server with Webmin.

Remove/Uninstall Webmin

To remove/uninstall Webmin on Debian 12, use the “autoremove” utility with the apt command:

sudo apt autoremove webmin

That is all from this section.

Method 2: Install Webmin on Debian 12 from setup-repos.sh Script

To install Webmin on Debian 12, use the “setup-repos.sh” script that is provided by the Webmin developers. This script adds the Webmin repository to the system and installs the latest version of Webmin. To install Webmin on Debian 12 from setup-repos.sh script, follow these steps:

Step 1: Install Dependencies

First, install the required dependent packages for the installation of webmin on Debian 12:

sudo apt install gnupg2 curl

Step 2: Download the Script

After that, download the setup-repos.sh script from the webmin repository to install Webmin automatically:

curl -o setup-repos.sh https://raw.githubusercontent.com/webmin/webmin/master/setup-repos.sh

Step 3: Make the script executable

Now, make the script executable by specifying the permission “+x” with the “chmod” command:

chmod +x setup-repos.sh

Step 4: Run .sh Script

In this step, run the downloaded script file as root as below:

sudo ./setup-repos.sh

Step 5: Install Webmin

To install Webmin, use the “install” utility by mentioning the “webmin” package name:

sudo apt install --install-recommends webmin

Step 6: Access Webmin Web Interface

Wait for the script to finish and confirm that Webmin is installed by visiting https://localhost:10000 in your browser. Login to Webmin with your root username and password and enjoy managing your system:

It pops up on the Dashboard as below:

Remove/Uninstall Webmin

To remove/uninstall Webmin on Debian 12, use the “autoremove” utility with the apt command:

sudo apt autoremove webmin

That is all from this section.

Method 3: Install Webmin on Debian 12 Using the .deb Package

To install Webmin on Debian 12 from a downloaded .deb package, follow the stated steps:

Step 1: Download Webmin .deb Package

First, users need to download the latest Webmin .deb package from the official website. For instance, use the wget command to do this:

wget https://sourceforge.net/projects/webadmin/files/webmin/2.105/webmin_2.105_all.deb

Step 2: Install the Webmin Package

Next, install the Webmin package with the help of the apt command. You may need to use sudo or become root to do this:

sudo dpkg -i webmin_2.105_all.deb

Note: if the user finds any dependencies issues, execute the below command:

sudo apt --fix-broken install

This installs Webmin and its dependencies on your system.

Step 3: Start and Enable Webmin Service

Finally, users need to start the Webmin service and enable it to run on boot:

sudo systemctl start webmin
sudo systemctl enable webmin

sudo systemctl status webmin

Step 4: Access Webmin Web Interface

Now, users can visit https://your_server_ip:10000 to access the Webmin by launching/opening your browser:

You will need to log in with your root username and password, or any other user who has sudo privileges:

In this way, Webmin has been successfully installed on Debian 12 from a downloaded .deb package. You can now use it to manage your system remotely and easily.

How to Configure/Manage Webmin on Debian 12?

Webmin provides an interface for controlling and managing Linux servers. You also need to open port 10000 in your firewall to access the Webmin web interface. Follow these steps to set it up:

First, ensure you have a Debian 12 server with a configured root password. To manage the Webmin service, follow the below instructions:

Start Webmin:

To start the Webmin service on Debian 12, use the “start” utility as below:

sudo service webmin start

Restart Webmin:

To restart the Webmin service on Debian 12, use the “restart” utility as below:

sudo service webmin restart

Check Webmin’s Status:

To manage the Webmin service on Debian 12, use the “status” utility as below:

sudo service webmin status

Stop Webmin:

To stop the Webmin service on Debian 12, use the “stop” utility as below:

service webmin stop

Configuring Webmin:

To customize Webmin, open the “miniserv.conf” configuration file:

sudo nano /etc/webmin/miniserv.conf

Modify the listen address if needed (e.g., set it to your IP address):

listen=YOUR_IP_ADDRESS

Save and close the file.

Restart the Webmin Service:

Finally, restart the Webmin Service with the help of the “systemctl” utility:

sudo systemctl restart webmin

Optional: Firewall Rules

For security, consider configuring your firewall (UFW) to allow ports 22 (SSH) and 10000 (Webmin):

sudo apt install ufw -y
sudo ufw allow 22
sudo ufw allow 10000
sudo ufw enable
sudo ufw status

Accessing Webmin:

Open a web browser and navigate to https://YOUR_IP_ADDRESS:10000 and Log in with your server’s credentials. Finally, explore Webmin’s features, including user management, Apache setup, DNS configuration, and more:

Remember that Webmin simplifies server administration, making it accessible even for beginners.

Conclusion

Webmin on Debian 12 allows users to perform tasks such as managing users, installing packages, configuring services, and more. To install Webmin on Debian 12, add its official repository to your sources.list file, then, update package lists and install Webmin using apt. Alternatively, use the setup-repos.sh script file, or .deb package to install Webmin on Debian 12.

To use Webmin, log in with a valid system username and password. Then, browse through the different modules and options available in Webmin and make changes as needed. To manage the Webmin service, start its service via the “sudo systemctl start webmin”. To stop its service, execute the “sudo systemctl stop webmin” script. To check the Webmin service status, execute the “sudo systemctl status webmin” command.

 

Print Friendly, PDF & Email
Categories