How To Install awstats on Ubuntu 20.04

In this tutorial we learn how to install awstats on Ubuntu 20.04. awstats is powerful and featureful web server log analyzer powerful and featureful web server log analyzer

Introduction

In this tutorial we learn how to install awstats on Ubuntu 20.04.

What is awstats

awstats is:

Advanced Web Statistics (AWStats) is a powerful web server logfile analyzer written in perl that shows you all your web statistics including visits, unique visitors, pages, hits, rush hours, search engines, keywords used to find your site, robots, broken links and more. Gives more detailed information and better graphical charts than webalizer, and is easier to use. Works with several web server log format as a CGI and/or from command line. Supports more than 30 languages.

Package: awstats Architecture: all Version: 7.6+dfsg-2 Priority: optional Section: web Origin: Ubuntu Maintainer: Ubuntu Developers [email protected] Original-Maintainer: Debian QA Group [email protected] Bugs: https://bugs.launchpad.net/ubuntu/+filebug Installed-Size: 6799 Depends: perl:any Recommends: libnet-xwhois-perl Suggests: apache2 | httpd, libnet-dns-perl, libnet-ip-perl, libgeo-ipfree-perl, liburi-perl Filename: pool/main/a/awstats/awstats_7.6+dfsg-2_all.deb Size: 1839348 MD5sum: cc5061152754d4d2d27ad56c9daeeff2 SHA1: fa2f8105c2f3a9d15e7fcd2224f6d22426e3b4a0 SHA256: fa824d26e8d9f9562ec35cedf81254784a9bf0beedbb290422c1b47151b9543d Homepage: http://awstats.sourceforge.net/ Description-en: powerful and featureful web server log analyzer Advanced Web Statistics (AWStats) is a powerful web server logfile analyzer written in perl that shows you all your web statistics including visits, unique visitors, pages, hits, rush hours, search engines, keywords used to find your site, robots, broken links and more. Gives more detailed information and better graphical charts than webalizer, and is easier to use. Works with several web server log format as a CGI and/or from command line. Supports more than 30 languages.

There are three methods to install awstats on Ubuntu 20.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install awstats Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install awstats using apt-get by running the following command:

sudo apt-get -y install awstats

Install awstats Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install awstats using apt by running the following command:

sudo apt -y install awstats

Install awstats Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install awstats using aptitude by running the following command:

sudo aptitude -y install awstats

How To Uninstall awstats on Ubuntu 20.04

To uninstall only the awstats package we can use the following command:

sudo apt-get remove awstats

Uninstall awstats And Its Dependencies

To uninstall awstats and its dependencies that are no longer needed by Ubuntu 20.04, we can use the command below:

sudo apt-get -y autoremove awstats

Remove awstats Configurations and Data

To remove awstats configuration and data from Ubuntu 20.04 we can use the following command:

sudo apt-get -y purge awstats

Remove awstats configuration, data, and all of its dependencies

We can use the following command to remove awstats configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge awstats

References

Summary

In this tutorial we learn how to install awstats package on Ubuntu 20.04 using different package management tools: apt, apt-get and aptitude.