Previous months' statistics get deleted after performing domain's statistics recalculation:
/usr/local/psa/admin/bin/statistics --calculate-one --domain-name=domain.tld
if Retain web and traffic statistics value of the corresponding domain is set to 0 using CLI, which according to the
/usr/local/psa/bin/service_plan utility should be specified to keep all statistics:
# /usr/local/psa/bin/service_plan --help | grep -A2 keep_traf_stat
-keep_traf_stat <number> Sets the system to retain traffic
statistics for N months (specify 0 if
you do not wish to delete statistics)
Such behavior was confirmed to be a software issue that should be fixed in one of the future releases, the internal issue with ID # PPPM-1411 has been submitted.
Please be informed that the issue is reported as fixed on latest Plesk Panel 11.5 version.
As a workaround you can set the
keep_traf_stat value to 9999999999999:
# /usr/local/psa/bin/service_plan -u "Domain Simple" -keep_traf_stat 9999999999999