Applicable to:
- Plesk Onyx for Linux
Symptoms
-
AWStats is not installed on the server;
-
access_log.webstat
persists in the directory for the domainexample.com
:# ls -l /var/www/vhosts/example.com/logs/access_log.webstat
-rw------- 2 root root 197718 Apr 3 13:50 /var/www/vhosts/example.com/logs/access_log.webstat
Cause
This is Plesk bug with ID PPPM-4718 which was fixed in Plesk Obsidian.
Resolution
Upgrade to the newest Plesk version: Upgrade Guide to Plesk Obsidian
Workaround
-
Connect to the server via SSH.
-
Install AWStats:
# plesk installer --select-release-current --install-component awstats
-
Execute the following in order to rotate
access_log.webstat
for domainexample.com
:# plesk sbin statistics --calculate-one --domain-name=example.com
or execute the following in order to rotate
access_log.webstat
for all domains:# plesk sbin statistics --calculate-all
Warning: This will effectively disable *.webstat files processing, but the files would still appear.
-
Connect to the server via SSH.
-
Execute the command below to disable
*.webstat
files processing:
On Debian-based:# echo -e '#!/bin/bash\necho' > /usr/lib/plesk-9.0/logresolvemerge
On RHEL-based:
# echo -e '#!/bin/bash\necho' > /usr/lib64/plesk-9.0/logresolvemerge
Warning: the utility is restored by Plesk upgrade or update installation. Apply the following steps for the script execution after each Plesk update:
-
Go to Tools & Settings > Even Manager > Add Event Handler.
-
Specify the following fields:
-
Event: Update installed
-
Priority: normal (50)
-
User: root
-
Command:
CONFIG_TEXT: echo -e '#!/bin/bash\necho' > /usr/lib64/plesk-9.0/logresolvemerge
-
Comments
10 comments
I have a similiar problem:
access_log.webstat & access_ssl_log.webstat file are not being rotated, though AWStats is installed. The files contain over a year old entries and those are getting bigger and bigger. What problem could it be even if AWStats is installed on the server? I´m running Plesk 17.5.3 Update 59 on a Ubuntu 16.04 LTS Linux. This goes for every domain that is created in Plesk. Lot´s of GBs wasted and could be spared if rotation would work correctly.
Hello @Sascha,
The case needs a deeper investigation.
As I can see, you have already submitted a ticket to Plesk Technical Support.
Currently, the ticket is worked on.
OS
Version 17.8.11 Update #54, last updated on June 3, 2019 03:43 AM
Hello @Ari Benami,
Currently, we have no information when the bug will be fixed
The "event handler" solution should not remove webstat files
It works for the case when the "/var/www/vhosts/system/example.com/logs/*.webstat" files are growing after the Daily Task execution and it is required to stop it
Warning: it affects the whole server
First of all, you execute this command:
As a result, you modify the "/usr/lib64/plesk-9.0/logresolvemerge" file and disable *.webstat files processing
However, Plesk update/upgrade rewrites the content of the "/usr/lib64/plesk-9.0/logresolvemerge" file
In order to avoid this, you have to add the corresponding Event Handler to Plesk which will be rewriting the "/usr/lib64/plesk-9.0/logresolvemerge" file automatically
In this case, webstat files will not continue growing
Also, you can install AWStats back and rotate .webstat files by following steps from the "Install web statistics tool" section. After this, disable AWStats on all affected domains via "Plesk > Domains > example.com > Hosting Settings > Web statistics" or "Plesk > Service Plans > Default > Hosting Parameters > Web statistics"
On my ubuntu 18.04 /usr/lib/plesk-9.0 there is no file named logresolvemerge
root@100asa:~# echo -e '#!/bin/bash\necho' > /usr/lib64/plesk-9.0/logresolvemerge
-bash: /usr/lib64/plesk-9.0/logresolvemerge: No such file or directory
Hello @Remigio Ruberto,
Thank you for the input!
The cause of such behavior is that the path /usr/lib64/plesk-9.0/logresolvemerge can be used for RHEL-based OS only.
To execute the command properly, please use the following command:
The article will be modified accordingly on this matter.
Guys, this is still a problem, the log files are still created for all domains, I am now upgraded to Obsidian, but still have to manually delete these obscene webstat log files.
neither Awstat nor Webalizer are installed.
1&1 Ticket no 151246 please help with fresh instructions!!
Hello Ari, it is needed to review server carefully. Please create a ticket to 1&1, they'll reach us from their side if won't be able to solve.
When is the problem expected to be resolved by Plesk's support team?
Hi @mw004 the issue has been fixed in Plesk 18 version already.
Please sign in to leave a comment.