Bobcares

AWStats DirectAdmin | Installation Guide

by | Aug 27, 2022

Let’s take a closer look at defining AWSTATS in DirectAdmin. At Bobcares, with our Server Management Services, we can handle your DirectAdmin AWStats issues.

AWStats In DirectAdmin

AWStats is an open-source server-based website log analysis tool that is suited for analyzing information from Internet services like the web, streaming media, mail, and FTP servers with packages readily accessible for the majority of Linux distributions. It is not a per-domain setting, but rather a global on/off switch.

Today we will explore more about integrating AWStats into DirectAdmin.

 

awstats directadmin

 

 

 

 

 

 

 

Downloading And Installing AWStats In DirectAdmin

In order to download and install the tool to the DirectAdmin, we can run the following command:

cd /usr/local/directadmin/scripts
./awstats.sh

This command will download and install the AWStats setup. It then adds awstats=1 and webalizer=0 to the directadmin.conf. The webalizer=0 code will shut off the Webalizer. If we want both, we can then override it. Also, insert AWStats as static HTML pages into:

/home/user/domains/domain.com/awstats

And store the config and tally data in:

/home/user/domains/domain.com/awstats/.data

Benefits Of AWStats In DirectAdmin

Some of the benefits we can consider include:

  • The integrated AWStats has a security advantage over many plugins. With this configuration, files are chowned to root and chmod to a minimal setting making things safe, secure, and private.
  • Subdomains will have their AWStats page with this configuration. DirectAdmin will also parse the AWStats data files to retrieve the bandwidth for the subdomains, thus as long as the parsing continues, the bandwidth for each subdomain will appear in DA on the subdomains page.
  • The benefit of storing the data in /home/user is that users can take it with them when they are relocating their accounts.
  • While creating the link, the ../stats symbolic link on the domain stats page will point to ../awstats.

Rather than being termed a disadvantage, I believe the following points as a reminder to keep in mind when using AWStats in DirectAdmin.

  • The way the configuration of log names in config files makes the rotation of Apache logs slightly different during the tally. Renaming all logs to .log prior to the tally will not occur. However, processing of logs will be in place.
  • This has the consequence of not sending a HUP to the master httpd process right before the tally. Also, Truncating logs is preferable rather than erasing logs during the cycle for each user.
  • Testers should keep a watch on the implications of truncating a live log without immediately restarting Apache. It will most likely be OK. Also, Apache will restart post-tally as usual.

How To Disable AWStats For Individual User Accounts?

With the new AWStats processing update, where saved data is now held by the user, this takes up more space. Because some users may not want this, the override allows us to disable AWStats processing for their account. Despite the directadmin.conf option, We can now change the:

/usr/local/directadmin/data/users/username/user.conf

And add:

awstats=0

To override the global setting:

CMD_USER_STATS

This will also fully disable CMD_AWSTATS. Most importantly, the awstats_process.sh will run for this User account.

[Searching for a solution to another question? Get in touch with us.]

Conclusion

In this article, we have explained the steps from our Support team for installing AWStats in DirectAdmin along with disabling it for per-User accounts.

PREVENT YOUR SERVER FROM CRASHING!

Never again lose customers to poor server speed! Let us help you.

Our server experts will monitor & maintain your server 24/7 so that it remains lightning fast and secure.

GET STARTED

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Never again lose customers to poor
server speed! Let us help you.

Privacy Preference Center

Necessary

Necessary cookies help make a website usable by enabling basic functions like page navigation and access to secure areas of the website. The website cannot function properly without these cookies.

PHPSESSID - Preserves user session state across page requests.

gdpr[consent_types] - Used to store user consents.

gdpr[allowed_cookies] - Used to store user allowed cookies.

PHPSESSID, gdpr[consent_types], gdpr[allowed_cookies]
PHPSESSID
WHMCSpKDlPzh2chML

Statistics

Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.

_ga - Preserves user session state across page requests.

_gat - Used by Google Analytics to throttle request rate

_gid - Registers a unique ID that is used to generate statistical data on how you use the website.

smartlookCookie - Used to collect user device and location information of the site visitors to improve the websites User Experience.

_ga, _gat, _gid
_ga, _gat, _gid
smartlookCookie
_clck, _clsk, CLID, ANONCHK, MR, MUID, SM

Marketing

Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.

IDE - Used by Google DoubleClick to register and report the website user's actions after viewing or clicking one of the advertiser's ads with the purpose of measuring the efficacy of an ad and to present targeted ads to the user.

test_cookie - Used to check if the user's browser supports cookies.

1P_JAR - Google cookie. These cookies are used to collect website statistics and track conversion rates.

NID - Registers a unique ID that identifies a returning user's device. The ID is used for serving ads that are most relevant to the user.

DV - Google ad personalisation

_reb2bgeo - The visitor's geographical location

_reb2bloaded - Whether or not the script loaded for the visitor

_reb2bref - The referring URL for the visit

_reb2bsessionID - The visitor's RB2B session ID

_reb2buid - The visitor's RB2B user ID

IDE, test_cookie, 1P_JAR, NID, DV, NID
IDE, test_cookie
1P_JAR, NID, DV
NID
hblid
_reb2bgeo, _reb2bloaded, _reb2bref, _reb2bsessionID, _reb2buid

Security

These are essential site cookies, used by the google reCAPTCHA. These cookies use an unique identifier to verify if a visitor is human or a bot.

SID, APISID, HSID, NID, PREF
SID, APISID, HSID, NID, PREF