Commit 8ba3585b authored by Jan Lindström's avatar Jan Lindström

MDEV-7168: Tests innodb.innodb_stats_create_table

innodb.innodb_stats_drop_locked fail and
innodb.innodb_stats_fetch_nonexistent fails in buildbot on Windows

Analysis: Problem is that innodb_stats_create_on_corrupted
test renames mysql.innodb.index_stats and all the rest
are dependend on this table.

Fix: After rename back to original, restart mysqld to
make sure that table is correct.
parent 1ac12df0
...@@ -17,4 +17,16 @@ avg_row_length 0 ...@@ -17,4 +17,16 @@ avg_row_length 0
max_data_length 0 max_data_length 0
index_length 0 index_length 0
ALTER TABLE mysql.innodb_index_stats_ RENAME TO mysql.innodb_index_stats; ALTER TABLE mysql.innodb_index_stats_ RENAME TO mysql.innodb_index_stats;
SELECT seq_in_index, column_name, cardinality
FROM information_schema.statistics WHERE table_name = 'test_ps_create_on_corrupted'
ORDER BY index_name, seq_in_index;
seq_in_index 1
column_name a
cardinality 0
SELECT table_rows, avg_row_length, max_data_length, index_length
FROM information_schema.tables WHERE table_name = 'test_ps_create_on_corrupted';
table_rows 0
avg_row_length 0
max_data_length 0
index_length 0
DROP TABLE test_ps_create_on_corrupted; DROP TABLE test_ps_create_on_corrupted;
...@@ -33,4 +33,16 @@ FROM information_schema.tables WHERE table_name = 'test_ps_create_on_corrupted'; ...@@ -33,4 +33,16 @@ FROM information_schema.tables WHERE table_name = 'test_ps_create_on_corrupted';
# restore the persistent storage # restore the persistent storage
ALTER TABLE mysql.innodb_index_stats_ RENAME TO mysql.innodb_index_stats; ALTER TABLE mysql.innodb_index_stats_ RENAME TO mysql.innodb_index_stats;
--source include/restart_mysqld.inc
-- vertical_results
# check again
SELECT seq_in_index, column_name, cardinality
FROM information_schema.statistics WHERE table_name = 'test_ps_create_on_corrupted'
ORDER BY index_name, seq_in_index;
SELECT table_rows, avg_row_length, max_data_length, index_length
FROM information_schema.tables WHERE table_name = 'test_ps_create_on_corrupted';
DROP TABLE test_ps_create_on_corrupted; DROP TABLE test_ps_create_on_corrupted;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment