- Plesk 12.0 for Linux
The upgrade from Plesk 12.0 was failed before any packages were downloaded.
The following error is shown upon the attempt to login to Plesk:
CONFIG_TEXT: ERROR: PleskMainDBException: MySQL query failed: Unknown column 'id' in 'field list'
Additionally, an exception has occurred while trying to report this error: Zend_Db_Statement_Exception
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'psa.ServiceInstallations' doesn't exist (db.php:91)
Plesk database schema was updated to a newer version.
Connect to the server via SSH.
Find the latest
# ls -lt /var/lib/psa/dumps
-rw------- 1 root root 2988 Sep 17 16:27 mysql.preupgrade.apsc.12.0.18-188.8.131.5280917-162700.dump.gz
-rw------- 1 root root 4008830 Sep 17 16:27 mysql.preupgrade.12.0.18-184.108.40.20680917-162657.dump.gz
Create a backup of the database in the current state:
cat /etc/psa/.psa.shadowmysqldump -u admin psa > /root/psabackup.sql
Restore the Plesk database from the pre-upgrade dump:
cat /etc/psa/.psa.shadowmysql -u admin -e"DROP DATABASE psa;"
# zcat /var/lib/psa/dumps/mysql.preupgrade.12.0.18-220.127.116.1180917-162657.dump.gz | sed -n '/-- Current Database:
psa/,/-- Current Database:*/p' | MYSQL_PWD=
cat /etc/psa/.psa.shadowmysql -f -uadmin
Note: before the attempt to upgrade Plesk again, review package manager configuration to make sure that the following command can be executed properly:
On Debian-based systems:
# apt-get upgrade
On RedHat-based systems:
# yum update