Bug #94303 util.checkForServerUpgrade reports missing tables in I_S.TABLES table

Submitted: 13 Feb 2019 5:42 Modified: 11 Mar 2019 15:51
Reporter: Jericho Rivera Email Updates:
Status: Closed Impact on me:
None 
Category:Shell Upgrade Checker Severity:S3 (Non-critical)
Version:8.0, 8.0.15 OS:Any
Assigned to: CPU Architecture:Any

[13 Feb 2019 5:42] Jericho Rivera
Description:
Reports missing tables for table names with a hyphen or dash in them.

---

13) Schema inconsistencies resulting from file removal or corruption
  Error: Following tables show signs that either table datadir directory or frm
    file was removed/corrupted. Please check server logs, examine datadir to
    detect the issue and fix it before upgrade

  test.t1@002d3 - present in INFORMATION_SCHEMA's INNODB_SYS_TABLES table but
    missing from TABLES table

---

Compare tables in I_S.innodb_sys_tables and I_S.tables:
mysql> select * from information_schema.innodb_sys_tables where name like 'test/%';
+----------+--------------------+------+--------+-------+-------------+------------+---------------+------------+
| TABLE_ID | NAME               | FLAG | N_COLS | SPACE | FILE_FORMAT | ROW_FORMAT | ZIP_PAGE_SIZE | SPACE_TYPE |
+----------+--------------------+------+--------+-------+-------------+------------+---------------+------------+
|       42 | test/proxysqltest  |   33 |      4 |    26 | Barracuda   | Dynamic    |             0 | Single     |
|       43 | test/queryruletest |   33 |      4 |    27 | Barracuda   | Dynamic    |             0 | Single     |
|       44 | test/t1@002d3      |   33 |      4 |    30 | Barracuda   | Dynamic    |             0 | Single     |
+----------+--------------------+------+--------+-------+-------------+------------+---------------+------------+

mysql> select table_schema,table_name,engine,row_format,update_time from information_schema.tables where table_schema like 'test';
+--------------+-----------------+--------+------------+---------------------+
| table_schema | table_name      | engine | row_format | update_time         |
+--------------+-----------------+--------+------------+---------------------+
| test         | myisamtabletest | MyISAM | Fixed      | 2019-01-15 03:41:51 |
| test         | proxysqltest    | InnoDB | Dynamic    | NULL                |
| test         | queryruletest   | InnoDB | Dynamic    | NULL                |
| test         | t1-3            | InnoDB | Dynamic    | NULL                |
+--------------+-----------------+--------+------------+---------------------+

How to repeat:
1. Create test.t1-3 table on latest version 5.7
create table `test`.`t1-3` (id int primary key) engine=innodb;

2. run util.checkForServerUpgrade
[13 Feb 2019 8:27] MySQL Verification Team
Hello Jericho Rivera,

Thank you for the report and feedback.

regards,
Umesh
[11 Mar 2019 15:51] Margaret Fisher
Posted by developer:
 
Changelog entry added for MySQL Shell 8.0.16:

MySQL Shell's upgrade checker utility checkForServerUpgrade() could incorrectly report a schema inconsistency error for a table whose name included a special character such as a hyphen.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.038 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.