Articles in this section

MySQL/MariaDB schema upgrade error: Incorrect database name '#mysql50#.ssh'

Plesk for Windows Plesk for Linux kb: technical ABT: Group A mysql

Applicable to:

  • Plesk for Linux
  • Plesk for Windows

Symptoms

  • Plesk upgrade fails during MySQL/MariaDB upgrade with one of these errors:

    Got error: 1102: Incorrect database name '#mysql50#example.database' when selecting the database

    Failed to install 'C:\ParallelsInstaller\parallels\PANEL-WIN_17.5.3\dist-msi-Mic
    rosoft-2003-i386\mysql-admin_mu067.msi': Fatal error during installation. (Error
    code 1603)

  • Upgrading the MySQL/MariaDB schema with mysql_upgrade fails:

    Failed to ALTER DATABASE `#mysql50#.ssh` UPGRADE DATA DIRECTORY NAME
    Error: Incorrect database name '#mysql50#.ssh'
    Running 'mysqlcheck with default connection arguments
    mysqlcheck: Got error: 1102: Incorrect database name '#mysql50#.ssh' when selecting the database
    FATAL ERROR: Error during call to mysql_check for upgrading the tables names.

  • There's a folder whose name starts with a dot "." in /var/lib/mysql/ directory.

Cause

The folder starting with a dot (".") in the MySQL/MariaDB datadir directory prevents the mysqlcheck command from running correctly.

Resolution

Move the dot folder outside datadir, which by default is:

  • /var/lib/mysql on Linux
  • %plesk_dir%Databases\MySQL\data\ or %plesk_dir%MySQL\Data\ on Windows

Note: If it's not any of the above, its location is defined by and can be found in the my.ini or my.cnf config files.

For Linux
  1. Connect to the server via SSH

  2. List all dot directories in datadir:

    # ls -la /var/lib/mysql | grep ^d | egrep '\.'

  3. Move any directory that starts with a dot to another location. For example:

    # mv /var/lib/mysql/.directory /root/

For Windows
  1. Connect to the server via RDP
  2. Open datadir folder %plesk_dir%Databases\MySQL\data\ or %plesk_dir%MySQL\Data\
  3. Find and move any directory with a starting dot to another location.
Was this article helpful?

Comments

0 comments

Please sign in to leave a comment.