1# 2# MDEV-24093: Detect during mysql_upgrade if type_mysql_json.so 3# is needed and load it 4# 5SET NAMES utf8; 6call mtr.add_suppression("Table rebuild required"); 7show create table mysql_json_test; 8ERROR HY000: Table rebuild required. Please do "ALTER TABLE `test.mysql_json_test` FORCE" or dump/reload to fix it! 9Phase 1/7: Checking and upgrading mysql database 10Processing databases 11mysql 12mysql.column_stats OK 13mysql.columns_priv OK 14mysql.db OK 15mysql.event OK 16mysql.func OK 17mysql.global_priv OK 18mysql.gtid_slave_pos OK 19mysql.help_category OK 20mysql.help_keyword OK 21mysql.help_relation OK 22mysql.help_topic OK 23mysql.index_stats OK 24mysql.innodb_index_stats 25Error : Unknown storage engine 'InnoDB' 26error : Corrupt 27mysql.innodb_table_stats 28Error : Unknown storage engine 'InnoDB' 29error : Corrupt 30mysql.plugin OK 31mysql.proc OK 32mysql.procs_priv OK 33mysql.proxies_priv OK 34mysql.roles_mapping OK 35mysql.servers OK 36mysql.table_stats OK 37mysql.tables_priv OK 38mysql.time_zone OK 39mysql.time_zone_leap_second OK 40mysql.time_zone_name OK 41mysql.time_zone_transition OK 42mysql.time_zone_transition_type OK 43mysql.transaction_registry 44Error : Unknown storage engine 'InnoDB' 45error : Corrupt 46 47Repairing tables 48mysql.innodb_index_stats 49Error : Unknown storage engine 'InnoDB' 50error : Corrupt 51mysql.innodb_table_stats 52Error : Unknown storage engine 'InnoDB' 53error : Corrupt 54mysql.transaction_registry 55Error : Unknown storage engine 'InnoDB' 56error : Corrupt 57Phase 2/7: Installing used storage engines... Skipped 58Phase 3/7: Fixing views 59mysql.user OK 60Phase 4/7: Running 'mysql_fix_privilege_tables' 61Phase 5/7: Fixing table and database names 62Phase 6/7: Checking and upgrading tables 63Processing databases 64information_schema 65mtr 66mtr.global_suppressions OK 67mtr.test_suppressions OK 68performance_schema 69test 70test.mysql_json_test Needs upgrade 71test.mysql_json_test_big Needs upgrade 72 73Repairing tables 74test.mysql_json_test OK 75test.mysql_json_test_big OK 76Phase 7/7: Running 'FLUSH PRIVILEGES' 77OK 78show create table mysql_json_test; 79Table Create Table 80mysql_json_test CREATE TABLE `mysql_json_test` ( 81 `description` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL, 82 `expected` longtext COLLATE utf8mb4_unicode_ci DEFAULT NULL, 83 `actual` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL 84) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci 85show create table mysql_json_test_big; 86Table Create Table 87mysql_json_test_big CREATE TABLE `mysql_json_test_big` ( 88 `description` varchar(100) COLLATE utf8mb4_unicode_ci DEFAULT NULL, 89 `expected` longtext COLLATE utf8mb4_unicode_ci DEFAULT NULL, 90 `actual` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL 91) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci 92select * from mysql.plugin; 93name dl 94drop table mysql_json_test; 95drop table mysql_json_test_big; 96