AWstats statistics pages are not updated: "Unable to execute awstats_buildstaticpages.pl"

Refers to:

  • Plesk 11.5 for Linux
  • Plesk 12.0 for Linux

Created:

2016-11-16 12:44:40 UTC

Modified:

2016-12-21 19:06:47 UTC

0

Was this article helpful?


Have more questions?

Submit a request

AWstats statistics pages are not updated: "Unable to execute awstats_buildstaticpages.pl"

Symptoms

AWstats pages are not updated for all domains on the server. An attempt to manually execute statistics utility produces errors:

`statistics_collector: Unable to execute /usr/share/awstats/awstats_buildstaticpages.pl -awstatsprog=/var/www/cgi-bin/awstats/awstats.pl -configdir=/usr/local/psa/etc/awstats -config=domain1.test-http -dir=/var/www/vhosts/domain1.test/statistics/webstat/current >/dev/null 2>&1`

System error 2: No such file or directory

Cause

The value of AWSTATS_TOOLS_D in /etc/psa/psa.conf is incorrect, or the AWstats installation is corrupted.

Resolution

  1. Find the location, where awstats_buildstaticpages.pl script is installed, using one of the following commands ( dpkg is for Debian/Ubuntu; rpm is for CentOS/RHEL/SuSE):

    # rpm -ql awstats | grep buildstaticpages
    # dpkg -L awstats | grep buildstaticpages
  2. Check if the file returned by the command on the previous step exists on the server:

    # dpkg -L awstats | grep buildstaticpages
    /usr/share/awstats/tools/awstats_buildstaticpages.pl
    # ls -l /usr/share/awstats/tools/awstats_buildstaticpages.pl
    -rwxr-xr-x 1 root root 19670 Jan 8 2012 /usr/share/awstats/tools/awstats_buildstaticpages.pl
  3. If the file does not exist, reinstall AWstats using Tools & Setings > Updates & Upgrades menu in Plesk.

  4. If awstats_buildstaticpages.pl file exists, open /etc/psa/psa.conf configuration file in editor and update the value of AWSTATS_TOOLS_D parameter to point to the directory, reported in the output of the rpm or dpkg command ( /usr/share/awstats/tools in the example above).

Warning : If the file is edited remotely (downloaded, updated, and uploaded again), make sure to use "text" transfer mode when uploading/downloading the file over FTP/SFTP.

  1. To recalculate AWstats statistics for the missing days, use the script from KB article \#213901965 .
Have more questions? Submit a request
Please sign in to leave a comment.