The web-statistics calculation does not work: The values at Tools & Settings > Traffic Usage by Domains (under Statistics) are not updated.
When manually recalculating the statistics for a domain, the operation fails with the following error message:
# /usr/local/psa/admin/sbin/statistics –calculate-one –domain-name=example.com
PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 62390354 bytes) in /usr/local/psa/admin/plib/Service/Agent/Transport/Local/Exec.php on line 240
PHP memory limit is exceeded.
Connect to the Plesk server via SSH.
memory_limitin PHP configuration of Plesk:
2.1. Open the file
/usr/local/psa/admin/conf/php.iniin a text editor. In this example, we are using the vi editor:
# vi /usr/local/psa/admin/conf/php.ini
2.2. Navigate to the line
memory_limitand increase the value to 1024M.
2.3. Save the changes and close the file.
sw-cp-serverservice to apply the changes:
# service sw-cp-server restart
Recalculate statistics for all domains with the command:
# /usr/local/psa/bin/sw-engine-pleskrun /usr/local/psa/admin/plib/DailyMaintainance/script.php -f ExecuteWebStatistics