Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Webmin Administrator's Cookbook

You're reading from   Webmin Administrator's Cookbook Over 100 recipes to leverage the features of Webmin and master the art of administering your web or database servers.

Arrow left icon
Product type Paperback
Published in Mar 2014
Publisher
ISBN-13 9781849515849
Length 376 pages
Edition Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Michal Karzynski Michal Karzynski
Author Profile Icon Michal Karzynski
Michal Karzynski
Arrow right icon
View More author details
Toc

Table of Contents (19) Chapters Close

Webmin Administrator's Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
1. Setting Up Your System FREE CHAPTER 2. User Management 3. Securing Your System 4. Controlling Your System 5. Monitoring Your System 6. Managing Files on Your System 7. Backing Up Your System 8. Running an Apache Web Server 9. Running a MySQL Database Server 10. Running a PostgreSQL Database Server 11. Running Web Applications 12. Setting Up an E-mail Server Index

Installing Webmin on a Debian-based system


Installing Webmin on a Debian-based system, such as Ubuntu or Linux Mint, is easy because we can rely on the excellent package management system called Advanced Packaging Tool (APT). APT resolves and installs dependencies automatically and also ensures that Webmin will be updated automatically when you perform a system update.

How to do it...

To install Webmin, perform the following steps:

  1. Webmin is not part of the standard Debian package repository, so your first step will be to add the URL of Webmin's repository to your package sources file. Open the /etc/apt/sources.list file in a text editor and add the following lines to it:

    deb http://download.webmin.com/download/repository sarge contrib
    deb http://webmin.mirror.somersettechsolutions.co.uk/repository sarge contrib

    Tip

    On most systems, the vi text editor is installed by default, but it may be a bit tricky if you haven't used it before. If you want an easy-to-use editor, try nano. You can install it by issuing the following command:

    $ sudo apt-get install nano
    

    After it's installed, you can use nano to edit the sources.list file by issuing the following command:

    $ sudo nano /etc/apt/sources.list
    
  2. We also need to add the GPG key with which Webmin's repository is signed to the list of keys used by APT to authenticate packages. This can be done by issuing the following command:

    $  wget -qO - http://www.webmin.com/jcameron-key.asc | sudo apt-key add -
    
  3. You can now refresh the APT cache to include the contents of Webmin's repository. This is done with the following command:

    $ sudo apt-get update
    
  4. With these preliminaries out of the way, you can install Webmin with the following command:

    $ sudo apt-get install webmin
    

How it works...

Webmin provides an online repository with DEB installation packages that are compatible with Debian-based systems. We need to give our system the address of this repository so that it can take advantage of it. The list of available repositories is kept in the /etc/apt/sources.list file as well as other *.list files stored in the /etc/apt/source.list.d/ directory.

Every package is cryptographically signed to ensure that even if someone breaks into the repository and uploads a package pretending to be Webmin, we don't install it by accident. We downloaded the public GPG key needed to verify this signature by using wget and added it to our list of trusted keys by using the apt-key add command.

GNU Privacy Guard (GPG) is an open source alternative to Pretty Good Privacy (PGP), a cryptographic software suite that provides encryption and authentication functions. Every Webmin package contains a GPG cryptographic signature, which could only be generated using a private key that is kept secret by Webmin's author Jamie Cameron. A corresponding public key, which is made freely available, may be used to verify that the signature was generated using that private key. If even a single bit of the package code were modified after the package was signed, the signature would not match anymore. This ensures that nobody tampers with Webmin on its way between the author and your system. APT checks the signature automatically, we just need to provide it with Webmin's public key.

Tip

If you want to be extra careful, you can check whether the public key you imported is actually the one belonging to Jamie Cameron. Issue the following command and verify that its output contains the same key fingerprint:

$ sudo apt-key fingerprint
/etc/apt/trusted.gpg
--------------------
pub   1024D/11F63C51 2002-02-28
      Key fingerprint = 1719 003A CE3E 5A41 E2DE  70DF D97A 3AE9 11F6 3C51
uid                  Jamie Cameron <jcameron@webmin.com>

By updating the APT cache, we ensure that our system becomes aware of packages available in the new repository. Then, we can install Webmin. APT not only resolves dependencies and installs more than just the Webmin package, but also other components it needs to run, including the Perl programming language and others.

There's more...

Webmin also provides a .deb (Debian software package) file that can be downloaded and installed manually. If you want to do it this way for some reason, you would need to follow these steps:

  1. Visit Webmin's Downloads page at http://www.webmin.com/download.html and copy the address of the current Debian package. The package file will be named webmin_NNN_all.deb, where NNN indicates the current version number.

  2. Download the package by using wget:

    $ wget http://prdownloads.sourceforge.net/webadmin/webmin_NNN_all.deb
    
  3. First, install all the packages that Webmin depends on using the following command:

    $ sudo apt-get install perl libapt-pkg-perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl apt-show-versions python
    
  4. Then, run the following command to install Webmin from the package file:

    $ sudo dpkg --install webmin_NNN_all.deb
    

    Tip

    Your system may complain that some other package needed by Webmin is missing. For instance, you could see an error message like the following:

    dpkg: dependency problems prevent configuration of webmin:
     webmin depends on PACKAGE-NAME; however:
      Package PACKAGE-NAME is not installed.
    

    If you see this error, you should install the package designated by PACKAGE-NAME before installing Webmin.

See also

More information about installing Webmin on a Debian-based system and about APT package management in general can be found at the following Webmin and Debian websites:

You have been reading a chapter from
Webmin Administrator's Cookbook
Published in: Mar 2014
Publisher:
ISBN-13: 9781849515849
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image