Plesk 8.6 Windows statistics.exe error

 Upgraded Windows Plesk 8.2 to 8.6 due to the statistics.exe processusing 100% CPU for > 12 hours causing the machine it become unresponsive.  The upgrade to Plesk 8.6 went surprisingly well and didn’t fatally break the system.

Two things did happen though:

1/ It reset permissions on custom installed components such as jMail etc.

2/ Statistics.exe appeared to have a bug in it causing it not to run at all.  Event viewer showed:

Error message: Faulting application statistics.exe, version 8.600.0.0, faulting module msvcr80.dll, version 8.0.50727.1433, fault address 0x00008aa0.

Parallels forum post discussed this issue (amoung other issues) and a patch was issued:

URL:

sergius presented the fix:

Gentlemen,

Thank you for the reports.

Please download updated modules SiteAppStatistics.dll, statistics.exe and copy it to %plesk_bin%.
Please backup old modules before copying.

Any feedback is appreciated.

The above patched dll and exe worked for me.

Plesk backup temporary file filling disk

It appears that the Plesk backup utility (pleskbackup Linux) writes to a temporary file prior to moving it to the final destination you’ve specified on the command line.

ie. When running:

/usr/local/psa/bin/pleskbackup all /mnt/nfsshare/pleskbackup.bak

Plesk writes the whole backup file to the local disk in /var/lib/psa/dumps/tmp/:

# ls -lah /var/lib/psa/dumps/tmp/
total 1.9G
drwx—— 2 psaadm psaadm 4.0K 2009-02-09 18:38 .
drwxr-xr-x 3 psaadm psaadm 4.0K 2009-02-09 10:17 ..
-rw-r–r– 1 root   root   1.9G 2009-02-09 18:44 fileTFzx5u

This is a problem when you’re low on disk space on the machine and you’re mounting a NFS drive to backup to… it obviously fills the disk quickly and the backup fails.

Note:

  • Restoration of the backup files created by the script below has not yet been tested
  • Disk may still fill up due to very large site… may have to symlink the psa tmp directory onto the NFS mount
  • Tested with psabackup from Plesk version 8.2.1
  • It turned out that the site used over 60% of available disk space so filled the disk every time.  Plus, Plesk backup/restore on Linux has known issues for site backup files larger than 2GB in size.  Will have to write a manual backup script to overcome this.

The script looked like below, but, will need to be updated to backup sites too large for pleskbackup to handle.  This may or may not work for you depending on the Plesk version you are using… use at own risk.

#!/bin/bash

dopleskbu () {
MYSQLPASS=`cat /etc/psa/.psa.shadow`
for DOMAIN in `mysql -Ns -uadmin -p$MYSQLPASS -Dpsa -e “select name from domains”`;
do /usr/local/psa/bin/pleskbackup domains $DOMAIN –exclude=DOMAIN_IF_YOU_WANT $FPATH.$DOMAIN.bak;
if [ $? == 0 ]; then
logger “$0 $DOMAIN backup complete”
else
logger “$0 $DOMAIN backup error”
fi
done;
}

FILENAME=pleskbackup.weekly
DIR=/mnt/backup
FPATH=$DIR/$FILENAME

# Main calls

dopleskbu
### END OF SCRIPT ###