Monday, 6 September 2010

mysql plesk error

After a mysql upgrade I got the following error while removing - adding users in mysql:
Error: Connection to the database server has failed:
Table ‘mysql.servers’ doesn’t exist

Solution (as root):

[root@server ~]# mysql_fix_privilege_tables --user=admin --password=<admin passord> --verbose

This script updates all the mysql privilege tables to be usable by
the current version of MySQL

ERROR 1060 (42S21) at line 102: Duplicate column name 'File_priv'
ERROR 1060 (42S21) at line 108: Duplicate column name 'Grant_priv'
ERROR 1060 (42S21) at line 109: Duplicate column name 'Grant_priv'
.
.
.
ERROR 1060 (42S21) at line 647: Duplicate column name 'db_collation'
ERROR 1060 (42S21) at line 653: Duplicate column name 'body_utf8'
ERROR 1054 (42S22) at line 663: Unknown column 'Trigger_priv' in 'where clause'
done

Done!

:)