Plesk : Upgrading failed with error while trying to execute SQL query

Upgrade version 8.6 failed. The following error is shown in upgrade log:

ERROR while trying to execute SQL query, the query was: DELETE FROM mysql.user WHERE user = ”; FLUSH PRIVILEGES;


STOP psa-8.6.0-cos4.build86080722.02 upgrading AT Thu Jun 11 00:57:52 CDT 2009

What does the error mean and how to resolve the problem?

Execution of query “FLUSH PRIVILEGES” is not possible because table ‘mysql.procs_priv’ is missing in database ‘mysql’.
To verify login to mysql and try the command:

mysql> flush privileges;
ERROR 1146 (42S02): Table ‘mysql.procs_priv’ doesn’t exist


In MySQL 5.0 you may create the table with the following query:

mysql> CREATE TABLE `procs_priv` (
`Host` char(60) collate utf8_bin NOT NULL default '',
`Db` char(64) collate utf8_bin NOT NULL default '',
`User` char(16) collate utf8_bin NOT NULL default '',
`Routine_name` char(64) collate utf8_bin NOT NULL default '',
`Routine_type` enum('FUNCTION','PROCEDURE') collate utf8_bin NOT NULL,
`Grantor` char(77) collate utf8_bin NOT NULL default '',
`Proc_priv` set('Execute','Alter Routine','Grant') character set utf8 NOT NULL default '',
`Timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
PRIMARY KEY (`Host`,`Db`,`User`,`Routine_name`,`Routine_type`),
KEY `Grantor` (`Grantor`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Procedure privileges'

After the table was created you may continue upgrading.

It is recommended to download Plesk distributive from Parallels website, unpack it and install packages with “rpm -Uvh”.

Note: Before executing this command, make sure that you have taken the full backup of MySQL.


cat /usr/share/mysql/mysql_fix_privilege_tables.sql | mysql --no-defaults --force --user=admin -p --host=localhost --database=mysql

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.