[Commits] b5285bd7e20: MDEV-11873 Unnecessary InnoDB warnings upon bootstrap

marko.makela at mariadb.com marko.makela at mariadb.com
Tue Mar 14 17:15:02 EET 2017


revision-id: b5285bd7e201ce522b42d18664f171a4e47f5ecd (mariadb-10.2.4-60-gb5285bd7e20)
parent(s): af6eee1fc5c40c73edb65c08d16929ccfdc1f5f0
author: Marko Mäkelä
committer: Marko Mäkelä
timestamp: 2017-03-14 17:11:46 +0200
message:

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.

---
 mysql-test/mysql-test-run.pl                            |  1 -
 mysql-test/suite/encryption/r/innodb_first_page.result  |  3 ---
 mysql-test/suite/encryption/t/innodb_first_page.test    | 17 +++--------------
 mysql-test/suite/galera/include/galera_sst_restore.inc  |  2 --
 mysql-test/suite/galera/r/galera_ist_mysqldump.result   |  2 --
 mysql-test/suite/galera/r/galera_sst_mysqldump.result   |  2 --
 .../suite/galera/r/galera_sst_mysqldump_with_key.result |  2 --
 mysql-test/suite/galera/r/mysql-wsrep#33.result         |  2 --
 mysql-test/suite/innodb/include/restart_and_reinit.inc  | 16 +++-------------
 storage/innobase/dict/dict0crea.cc                      | 11 +----------
 10 files changed, 7 insertions(+), 51 deletions(-)

diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl
index 4fe0c253a78..dbc2c775e72 100755
--- a/mysql-test/mysql-test-run.pl
+++ b/mysql-test/mysql-test-run.pl
@@ -4419,7 +4419,6 @@ sub extract_warning_lines ($$) {
      qr|InnoDB: TABLE to scan your table for corruption|,
      qr/InnoDB: See also */,
      qr/InnoDB: Cannot open .*ib_buffer_pool.* for reading: No such file or directory*/,
-     qr|InnoDB: Creating foreign key constraint system tables.|,
      qr/InnoDB: Table .*mysql.*innodb_table_stats.* not found./,
      qr/InnoDB: User stopword table .* does not exist./
 
diff --git a/mysql-test/suite/encryption/r/innodb_first_page.result b/mysql-test/suite/encryption/r/innodb_first_page.result
index c2bbdb5695b..aaef462e639 100644
--- a/mysql-test/suite/encryption/r/innodb_first_page.result
+++ b/mysql-test/suite/encryption/r/innodb_first_page.result
@@ -1,5 +1,2 @@
-call mtr.add_suppression("InnoDB: New log files created, LSN");
-call mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
-shutdown;
 create table t1 (a int);
 drop table t1;
diff --git a/mysql-test/suite/encryption/t/innodb_first_page.test b/mysql-test/suite/encryption/t/innodb_first_page.test
index a0c563b1854..58095e5e110 100644
--- a/mysql-test/suite/encryption/t/innodb_first_page.test
+++ b/mysql-test/suite/encryption/t/innodb_first_page.test
@@ -5,25 +5,14 @@
 --source include/have_innodb.inc
 --source include/have_file_key_management_plugin.inc
 
-call mtr.add_suppression("InnoDB: New log files created, LSN");
-call mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
-
-let datadir=`select @@datadir`;
-
---exec echo wait > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
-
-shutdown;
-
---source include/wait_until_disconnected.inc
+let $datadir=`select @@datadir`;
+--source include/shutdown_mysqld.inc
 
 --remove_file $datadir/ib_logfile0
 --remove_file $datadir/ib_logfile1
 --remove_file $datadir/ibdata1
 
---exec echo restart > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
-
---enable_reconnect
---source include/wait_until_connected_again.inc
+--source include/start_mysqld.inc
 
 create table t1 (a int);
 
diff --git a/mysql-test/suite/galera/include/galera_sst_restore.inc b/mysql-test/suite/galera/include/galera_sst_restore.inc
index a08b148c31a..7c9a08090ad 100644
--- a/mysql-test/suite/galera/include/galera_sst_restore.inc
+++ b/mysql-test/suite/galera/include/galera_sst_restore.inc
@@ -16,8 +16,6 @@ DROP USER sst;
 --connection node_2
 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");
 CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
-CALL mtr.add_suppression("InnoDB: New log files created");
-CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
 CALL mtr.add_suppression("Can't open and lock time zone table");
 CALL mtr.add_suppression("Can't open and lock privilege tables");
 CALL mtr.add_suppression("Info table is not ready to be used");
diff --git a/mysql-test/suite/galera/r/galera_ist_mysqldump.result b/mysql-test/suite/galera/r/galera_ist_mysqldump.result
index 788d60051b5..8d0010afc44 100644
--- a/mysql-test/suite/galera/r/galera_ist_mysqldump.result
+++ b/mysql-test/suite/galera/r/galera_ist_mysqldump.result
@@ -277,8 +277,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
 DROP USER sst;
 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");
 CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
-CALL mtr.add_suppression("InnoDB: New log files created");
-CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
 CALL mtr.add_suppression("Can't open and lock time zone table");
 CALL mtr.add_suppression("Can't open and lock privilege tables");
 CALL mtr.add_suppression("Info table is not ready to be used");
diff --git a/mysql-test/suite/galera/r/galera_sst_mysqldump.result b/mysql-test/suite/galera/r/galera_sst_mysqldump.result
index 5c0d9a45d41..304ce165f3e 100644
--- a/mysql-test/suite/galera/r/galera_sst_mysqldump.result
+++ b/mysql-test/suite/galera/r/galera_sst_mysqldump.result
@@ -452,8 +452,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
 DROP USER sst;
 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");
 CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
-CALL mtr.add_suppression("InnoDB: New log files created");
-CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
 CALL mtr.add_suppression("Can't open and lock time zone table");
 CALL mtr.add_suppression("Can't open and lock privilege tables");
 CALL mtr.add_suppression("Info table is not ready to be used");
diff --git a/mysql-test/suite/galera/r/galera_sst_mysqldump_with_key.result b/mysql-test/suite/galera/r/galera_sst_mysqldump_with_key.result
index 227e1c15444..0a88b290e59 100644
--- a/mysql-test/suite/galera/r/galera_sst_mysqldump_with_key.result
+++ b/mysql-test/suite/galera/r/galera_sst_mysqldump_with_key.result
@@ -98,8 +98,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
 DROP USER sst;
 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");
 CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
-CALL mtr.add_suppression("InnoDB: New log files created");
-CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
 CALL mtr.add_suppression("Can't open and lock time zone table");
 CALL mtr.add_suppression("Can't open and lock privilege tables");
 CALL mtr.add_suppression("Info table is not ready to be used");
diff --git a/mysql-test/suite/galera/r/mysql-wsrep#33.result b/mysql-test/suite/galera/r/mysql-wsrep#33.result
index fc647a2000d..1c4bbc3f369 100644
--- a/mysql-test/suite/galera/r/mysql-wsrep#33.result
+++ b/mysql-test/suite/galera/r/mysql-wsrep#33.result
@@ -94,8 +94,6 @@ CALL mtr.add_suppression("Slave SQL: Error 'The MySQL server is running with the
 DROP USER sst;
 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");
 CALL mtr.add_suppression("InnoDB: Error: Table \"mysql\"\\.\"innodb_index_stats\" not found");
-CALL mtr.add_suppression("InnoDB: New log files created");
-CALL mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
 CALL mtr.add_suppression("Can't open and lock time zone table");
 CALL mtr.add_suppression("Can't open and lock privilege tables");
 CALL mtr.add_suppression("Info table is not ready to be used");
diff --git a/mysql-test/suite/innodb/include/restart_and_reinit.inc b/mysql-test/suite/innodb/include/restart_and_reinit.inc
index 9df66196edf..b3f7cae6d17 100644
--- a/mysql-test/suite/innodb/include/restart_and_reinit.inc
+++ b/mysql-test/suite/innodb/include/restart_and_reinit.inc
@@ -6,26 +6,16 @@
 source include/not_embedded.inc;
 
 --disable_query_log
-call mtr.add_suppression("InnoDB: New log files created");
-call mtr.add_suppression("InnoDB: Creating foreign key constraint system tables");
-
 let $innodb_index_stats = query_get_value(show create table mysql.innodb_index_stats, Create Table, 1);
 let $innodb_table_stats = query_get_value(show create table mysql.innodb_table_stats, Create Table, 1);
 let $database=`select database()`;
 drop table mysql.innodb_index_stats, mysql.innodb_table_stats;
 
-let $_server_id= `SELECT @@server_id`;
-let $_expect_file_name= $MYSQLTEST_VARDIR/tmp/mysqld.$_server_id.expect;
 let $datadir= `SELECT @@datadir`;
-exec echo "wait" > $_expect_file_name;
-shutdown_server;
-remove_file $datadir/ib_logfile0;
-remove_file $datadir/ib_logfile1;
+--source include/shutdown_mysqld.inc
+remove_files_wildcard $datadir ib_logfile*;
 remove_file $datadir/ibdata1;
-exec echo "restart" > $_expect_file_name;
-enable_reconnect;
-source include/wait_until_connected_again.inc;
-disable_reconnect;
+--source include/start_mysqld.inc
 
 --disable_query_log
 use mysql;
diff --git a/storage/innobase/dict/dict0crea.cc b/storage/innobase/dict/dict0crea.cc
index 084d39fc4a1..340048dbfe3 100644
--- a/storage/innobase/dict/dict0crea.cc
+++ b/storage/innobase/dict/dict0crea.cc
@@ -1702,7 +1702,7 @@ dict_create_or_check_foreign_constraint_tables(void)
 		row_drop_table_for_mysql("SYS_FOREIGN_COLS", trx, TRUE, TRUE);
 	}
 
-	ib::warn() << "Creating foreign key constraint system tables.";
+	ib::info() << "Creating foreign key constraint system tables.";
 
 	/* NOTE: in dict_load_foreigns we use the fact that
 	there are 2 secondary indexes on SYS_FOREIGN, and they
@@ -1767,10 +1767,6 @@ dict_create_or_check_foreign_constraint_tables(void)
 
 	srv_file_per_table = srv_file_per_table_backup;
 
-	if (err == DB_SUCCESS) {
-		ib::info() << "Foreign key constraint system tables created";
-	}
-
 	/* Note: The master thread has not been started at this point. */
 	/* Confirm and move to the non-LRU part of the table LRU list. */
 	sys_foreign_err = dict_check_if_system_table_exists(
@@ -1875,10 +1871,6 @@ dict_create_or_check_sys_virtual()
 
 	srv_file_per_table = srv_file_per_table_backup;
 
-	if (err == DB_SUCCESS) {
-		ib::info() << "sys_virtual table created";
-	}
-
 	/* Note: The master thread has not been started at this point. */
 	/* Confirm and move to the non-LRU part of the table LRU list. */
 	dberr_t sys_virtual_err = dict_check_if_system_table_exists(
@@ -2543,7 +2535,6 @@ dict_create_or_check_sys_tablespace(void)
 	srv_file_per_table = srv_file_per_table_backup;
 
 	if (err == DB_SUCCESS) {
-		ib::info() << "Tablespace and datafile system tables created.";
 		srv_sys_tablespaces_open = true;
 	}
 


More information about the commits mailing list