[HUB] Troubleshooting Statistics Issues in Plesk for Linux

Created:

2016-11-16 13:11:56 UTC

Modified:

2017-04-24 11:54:55 UTC

0

Was this article helpful?


Have more questions?

Submit a request

[HUB] Troubleshooting Statistics Issues in Plesk for Linux

Applicable to:

  • Plesk 12.5 for Linux
  • Plesk 10.4 for Linux
  • Plesk 11.0 for Linux
  • Plesk 12.0 for Linux

Before the following steps below, it is recommended to understand the process of statistics calculation.

Statistics utility

Statistics utility records monthly statistical data to psa tables and located at:

/usr/local/psa/admin/sbin/statistics

The utility performs the following tasks:

  • Processes the following log files for the services producing the majority of network traffic:
  • Apache logs under /var/www/vhosts/<domain_name>/statistics/logs/
  • FTP logs for authorized users /usr/local/psa/var/log/xferlog
  • FTP logs for anonymous users /var/www/vhosts/<domain_name>/statistics/logs/xferlog
  • Mail service logs /usr/local/psa/var/log/maillog

  • Extracts information from the above log files to the *.processed file and saves results in the following tables of the psa database:

  • DomainsTraffic

  • ClientsTraffic

  • Calls the logrotate utility from /usr/local/psa/logrotate/sbin/ which creates a rotation job according to /usr/local/psa/etc/logrotate.conf file.

The cron daemon launches the statistics utility once a day, using the command:

/usr/local/psa/admin/sbin/statistics > /dev/null 2>&1

Webalizer/AWStats utility

/usr/local/psa/admin/sbin/webstatmng

Webalizer converts the statistical information in user friendly format ( .html ).

Plesk 11:

Webstat: /var/www/vhosts/example.com/statistics/webstat
FTPstat: /var/www/vhosts/example.com/statistics/ftpstat/current/

Plesk 11.5 and higher:

Webstat: /var/www/vhosts/system/example.com/statistics/webstat
FTPstat: /var/www/vhosts/system/example.com/statistics/ftpstat/current/

By default this utility will be executed while running the daily maintenance script:

/usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php

Web statistic files can be manually generated by the following command:

/usr/local/psa/admin/bin/statistics --generate-domain-webstat -d example.com

AWStats configuration files located at:

/usr/local/psa/etc/awstats/

Webalizer configuration files located at:

/var/www/vhosts/example.com/conf/webalizer.conf

Troubleshooting

  1. Try to calculate statistic for one domain according to #213936305 article. In case when statistics have been generated successfully, go to next step.

  2. Enable logging of daily maintenance task according to the #213394209 article and monitor it within the next 24 hours.

If after some investigations it is required to generate statistic from a particular date use #213901965 article.

For other issues please check the articles below or contact Plesk Technical Support :

Useful KB articles

#213936305 - How to recalculate statistics for a particular domain on Plesk for Llinux?

#213901965 - How to recalculate AWStats statistics from logs for previous months

#213950065 - How to rerun daily maintenance tasks separately

#213369069 - Domain statistics are not calculated if the 'cronie' and 'cronie-anacron' packages are installed

#213394209 - How to enable logging of daily maintenance task

#213372649 Statisic calculation fails with "No such file or directory" error.

#213902565 Webalizer statistics is not being udpated: "Unable to restore run data"

#213399449 AWStats fails to calculate statistics for domain

#213381509 Statistics could not be updated automatically

#213951505 Different statistics values in web statistic and in Plesk.

Have more questions? Submit a request
Please sign in to leave a comment.