• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Upgrade 12.0.18 => 12.5.30 fails. The table "servers" in the database "mysql" does not exist

MichaelS

New Pleskian
Trying to upgrade version 12.0.18 to 12.5.30 but get this error

WARNING: [MYSQL ERROR] Unable to execute query. Error: Unknown column 'mysql' in 'where clause'
PHP Warning: mysql_fetch_assoc() expects parameter 1 to be resource, boolean given in /root/parallels/PSA_12.5.30/examiners/panel_preupgrade_checker.php on line 2779
WARNING: The table "servers" in the database "mysql" does not exist. Please check http://kb.odin.com/en/112290 for details.

My problem is that the table "servers" does exist in the mysql database...
 
Are you sure that you have correct structure of this table?

mysql> desc servers;
+-------------+----------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------------+----------+------+-----+---------+-------+
| Server_name | char(64) | NO | PRI | | |
| Host | char(64) | NO | | | |
| Db | char(64) | NO | | | |
| Username | char(64) | NO | | | |
| Password | char(64) | NO | | | |
| Port | int(4) | NO | | 0 | |
| Socket | char(64) | NO | | | |
| Wrapper | char(64) | NO | | | |
| Owner | char(64) | NO | | | |
+-------------+----------+------+-----+---------+-------+
9 rows in set (0.00 sec)
 
As I can see my table is exactly the same...

Field Type Null Key Default Extra
Server_name char(64) NO PRI
Host char(64) NO
Db char(64) NO
Username char(64) NO
Password char(64) NO
Port int(4) NO 0
Socket char(64) NO
Wrapper char(64) NO
Owner char(64) NO
 
I found the error

In /root/parallels/PSA_12.5.30/examiners/panel_preupgrade_checker.php is this line

SELECT * FROM information_schema.TABLES WHERE TABLE_SCHEMA="mysql" and TABLE_NAME="servers"

When i run this in phpMyAdmin i get the same error as the upgradescript.

But if I change " to ' it works - but how do I implement this in the panel_preupgrade_checker? - if I change manually the update function removes my changes.
 
Hi all
I have exactly the same problem!
Can anybody help me?
Thanks
 

Attachments

  • plesk_error_sql.jpg
    plesk_error_sql.jpg
    36.4 KB · Views: 3
  • plesk_error_sql2.jpg
    plesk_error_sql2.jpg
    50.9 KB · Views: 2
The problem apparently is on the line 1911 (/root/parallels/PSA_12.5.30/examiners/panel_preupgrade_checker.php), which says:

$sql = 'SELECT * FROM information_schema.TABLES WHERE TABLE_SCHEMA="mysql" and TABLE_NAME="servers"';
(The double quote " is actually specifying a field or an identifier. Use single quotes to specify your STRING filters)

I should say:

$sql = "SELECT * FROM information_schema.TABLES WHERE TABLE_SCHEMA='mysql' and TABLE_NAME='servers'";

The strange thing is that in a server models if it works with double quotes and not in another. (Same servers, miasma version of CentOS, etc).

if I edit the line and try to manually update the line is changed to the original.

to do in this case? Without this I can not update.

Regards
 

Attachments

  • plesk_error_sql3.jpg
    plesk_error_sql3.jpg
    89.9 KB · Views: 4
Last edited:
Back
Top