Skip to content

Commit b5285bd

Browse files
committed
MDEV-11873 Unnecessary InnoDB warnings upon bootstrap
dict_create_or_check_foreign_constraint_tables(): Change the warning about the foreign key metadata table creation to a note. Remove messages after metadata table creation. If the creation fails, startup will abort with a message. Normally the creation succeeds on bootstrap, and the messages would only be noise. Remove the related suppressions from the tests.
1 parent af6eee1 commit b5285bd

File tree

10 files changed

+7
-51
lines changed

10 files changed

+7
-51
lines changed

mysql-test/mysql-test-run.pl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4419,7 +4419,6 @@ ($$)
44194419
qr|InnoDB: TABLE to scan your table for corruption|,
44204420
qr/InnoDB: See also */,
44214421
qr/InnoDB: Cannot open .*ib_buffer_pool.* for reading: No such file or directory*/,
4422-
qr|InnoDB: Creating foreign key constraint system tables.|,
44234422
qr/InnoDB: Table .*mysql.*innodb_table_stats.* not found./,
44244423
qr/InnoDB: User stopword table .* does not exist./
44254424

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,2 @@
1-
call mtr.add_suppression("InnoDB: New log files created, LSN");
2-
call mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
3-
shutdown;
41
create table t1 (a int);
52
drop table t1;

mysql-test/suite/encryption/t/innodb_first_page.test

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,25 +5,14 @@
55
--source include/have_innodb.inc
66
--source include/have_file_key_management_plugin.inc
77

8-
call mtr.add_suppression("InnoDB: New log files created, LSN");
9-
call mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
10-
11-
let datadir=`select @@datadir`;
12-
13-
--exec echo wait > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
14-
15-
shutdown;
16-
17-
--source include/wait_until_disconnected.inc
8+
let $datadir=`select @@datadir`;
9+
--source include/shutdown_mysqld.inc
1810

1911
--remove_file $datadir/ib_logfile0
2012
--remove_file $datadir/ib_logfile1
2113
--remove_file $datadir/ibdata1
2214

23-
--exec echo restart > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
24-
25-
--enable_reconnect
26-
--source include/wait_until_connected_again.inc
15+
--source include/start_mysqld.inc
2716

2817
create table t1 (a int);
2918

mysql-test/suite/galera/include/galera_sst_restore.inc

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,6 @@ DROP USER sst;
1616
--connection node_2
1717
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
1818
CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
19-
CALL mtr.add_suppression("InnoDB: New log files created");
20-
CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
2119
CALL mtr.add_suppression("Can't open and lock time zone table");
2220
CALL mtr.add_suppression("Can't open and lock privilege tables");
2321
CALL mtr.add_suppression("Info table is not ready to be used");

mysql-test/suite/galera/r/galera_ist_mysqldump.result

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -277,8 +277,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
277277
DROP USER sst;
278278
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
279279
CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
280-
CALL mtr.add_suppression("InnoDB: New log files created");
281-
CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
282280
CALL mtr.add_suppression("Can't open and lock time zone table");
283281
CALL mtr.add_suppression("Can't open and lock privilege tables");
284282
CALL mtr.add_suppression("Info table is not ready to be used");

mysql-test/suite/galera/r/galera_sst_mysqldump.result

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -452,8 +452,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
452452
DROP USER sst;
453453
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
454454
CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
455-
CALL mtr.add_suppression("InnoDB: New log files created");
456-
CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
457455
CALL mtr.add_suppression("Can't open and lock time zone table");
458456
CALL mtr.add_suppression("Can't open and lock privilege tables");
459457
CALL mtr.add_suppression("Info table is not ready to be used");

mysql-test/suite/galera/r/galera_sst_mysqldump_with_key.result

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
9898
DROP USER sst;
9999
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
100100
CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
101-
CALL mtr.add_suppression("InnoDB: New log files created");
102-
CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
103101
CALL mtr.add_suppression("Can't open and lock time zone table");
104102
CALL mtr.add_suppression("Can't open and lock privilege tables");
105103
CALL mtr.add_suppression("Info table is not ready to be used");

mysql-test/suite/galera/r/mysql-wsrep#33.result

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
9494
DROP USER sst;
9595
CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement' on query");
9696
CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
97-
CALL mtr.add_suppression("InnoDB: New log files created");
98-
CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
9997
CALL mtr.add_suppression("Can't open and lock time zone table");
10098
CALL mtr.add_suppression("Can't open and lock privilege tables");
10199
CALL mtr.add_suppression("Info table is not ready to be used");

mysql-test/suite/innodb/include/restart_and_reinit.inc

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -6,26 +6,16 @@
66
source include/not_embedded.inc;
77

88
--disable_query_log
9-
call mtr.add_suppression("InnoDB: New log files created");
10-
call mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
11-
129
let $innodb_index_stats = query_get_value(show create table mysql.innodb_index_stats, Create Table, 1);
1310
let $innodb_table_stats = query_get_value(show create table mysql.innodb_table_stats, Create Table, 1);
1411
let $database=`select database()`;
1512
drop table mysql.innodb_index_stats, mysql.innodb_table_stats;
1613

17-
let $_server_id= `SELECT @@server_id`;
18-
let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$_server_id.expect;
1914
let $datadir= `SELECT @@datadir`;
20-
exec echo "wait" > $_expect_file_name;
21-
shutdown_server;
22-
remove_file $datadir/ib_logfile0;
23-
remove_file $datadir/ib_logfile1;
15+
--source include/shutdown_mysqld.inc
16+
remove_files_wildcard $datadir ib_logfile*;
2417
remove_file $datadir/ibdata1;
25-
exec echo "restart" > $_expect_file_name;
26-
enable_reconnect;
27-
source include/wait_until_connected_again.inc;
28-
disable_reconnect;
18+
--source include/start_mysqld.inc
2919

3020
--disable_query_log
3121
use mysql;

storage/innobase/dict/dict0crea.cc

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1702,7 +1702,7 @@ dict_create_or_check_foreign_constraint_tables(void)
17021702
row_drop_table_for_mysql("SYS_FOREIGN_COLS", trx, TRUE, TRUE);
17031703
}
17041704

1705-
ib::warn() << "Creating foreign key constraint system tables.";
1705+
ib::info() << "Creating foreign key constraint system tables.";
17061706

17071707
/* NOTE: in dict_load_foreigns we use the fact that
17081708
there are 2 secondary indexes on SYS_FOREIGN, and they
@@ -1767,10 +1767,6 @@ dict_create_or_check_foreign_constraint_tables(void)
17671767

17681768
srv_file_per_table = srv_file_per_table_backup;
17691769

1770-
if (err == DB_SUCCESS) {
1771-
ib::info() << "Foreign key constraint system tables created";
1772-
}
1773-
17741770
/* Note: The master thread has not been started at this point. */
17751771
/* Confirm and move to the non-LRU part of the table LRU list. */
17761772
sys_foreign_err = dict_check_if_system_table_exists(
@@ -1875,10 +1871,6 @@ dict_create_or_check_sys_virtual()
18751871

18761872
srv_file_per_table = srv_file_per_table_backup;
18771873

1878-
if (err == DB_SUCCESS) {
1879-
ib::info() << "sys_virtual table created";
1880-
}
1881-
18821874
/* Note: The master thread has not been started at this point. */
18831875
/* Confirm and move to the non-LRU part of the table LRU list. */
18841876
dberr_t sys_virtual_err = dict_check_if_system_table_exists(
@@ -2543,7 +2535,6 @@ dict_create_or_check_sys_tablespace(void)
25432535
srv_file_per_table = srv_file_per_table_backup;
25442536

25452537
if (err == DB_SUCCESS) {
2546-
ib::info() << "Tablespace and datafile system tables created.";
25472538
srv_sys_tablespaces_open = true;
25482539
}
25492540

0 commit comments

Comments
 (0)