diff options
author | Vicențiu Ciorbaru <vicentiu@mariadb.org> | 2018-04-09 16:49:41 +0300 |
---|---|---|
committer | Vicențiu Ciorbaru <vicentiu@mariadb.org> | 2018-04-09 16:49:41 +0300 |
commit | 8ff897265a32898dd533c8da504937872ffa3935 (patch) | |
tree | 09461866ac69d85bd9289e04183a00c7aca4ec8d /mysql-test/r | |
parent | 803ded51484255aa0c3201aebecfe45e11482653 (diff) | |
download | mariadb-git-8ff897265a32898dd533c8da504937872ffa3935.tar.gz |
Update test cases post MDEV-10286
Table_open_cache gets adjusted on server startup to prevent an out of
file descriptor error. However this means that when we reset its value
to default, it does not get re-adjusted. This leads to the mtr
consistency check to fail with different server status at the end of the
test case as opposed to when it started.
To fix the problem, do not make use of the DEFAULT keyword to set the
variable back, instead save the value before any modifications and
restore it from there.
Diffstat (limited to 'mysql-test/r')
-rw-r--r-- | mysql-test/r/myisam.result | 3 | ||||
-rw-r--r-- | mysql-test/r/myisam_recover.result | 3 | ||||
-rw-r--r-- | mysql-test/r/variables.result | 3 |
3 files changed, 6 insertions, 3 deletions
diff --git a/mysql-test/r/myisam.result b/mysql-test/r/myisam.result index 0f865c151fa..3af64bbd0de 100644 --- a/mysql-test/r/myisam.result +++ b/mysql-test/r/myisam.result @@ -1906,6 +1906,7 @@ DROP TABLE t1; # # BUG#48438 - crash with error in unioned query against merge table and view... # +SET @save_table_open_cache=@@table_open_cache; SET GLOBAL table_open_cache=10; CREATE TABLE t1(a INT); SELECT 1 FROM t1 AS a1, t1 AS a2, t1 AS a3, t1 AS a4, t1 AS a5, t1 AS a6, t1 AS a7, t1 AS a8, t1 AS a9, t1 AS a10, t1 AS a11 FOR UPDATE; @@ -1915,7 +1916,7 @@ WHERE TABLE_SCHEMA='test' AND TABLE_NAME='t1'; TABLE_ROWS DATA_LENGTH 0 0 DROP TABLE t1; -SET GLOBAL table_open_cache=DEFAULT; +SET GLOBAL table_open_cache=@save_table_open_cache; End of 5.0 tests create table t1 (a int not null, key `a` (a) key_block_size=1024); show create table t1; diff --git a/mysql-test/r/myisam_recover.result b/mysql-test/r/myisam_recover.result index 0829c1e8b82..6ae282cb2b6 100644 --- a/mysql-test/r/myisam_recover.result +++ b/mysql-test/r/myisam_recover.result @@ -18,6 +18,7 @@ call mtr.add_suppression("Got an error from thread_id=.*ha_myisam.cc:"); call mtr.add_suppression("MySQL thread id .*, query id .* localhost.*root Checking table"); call mtr.add_suppression(" '\..test.t1'"); +set @save_table_open_cache=@@table_open_cache; set global table_open_cache=256; set global table_definition_cache=400; drop procedure if exists p_create; @@ -102,7 +103,7 @@ prepare stmt from @drop_table_stmt; execute stmt; deallocate prepare stmt; set @@global.table_definition_cache=default; -set @@global.table_open_cache=default; +set @@global.table_open_cache=@save_table_open_cache; # # 18075170 - sql node restart required to avoid deadlock after # restore diff --git a/mysql-test/r/variables.result b/mysql-test/r/variables.result index a01c8f48a4d..df0d16237ac 100644 --- a/mysql-test/r/variables.result +++ b/mysql-test/r/variables.result @@ -568,6 +568,7 @@ set sql_safe_updates=1; set sql_select_limit=1; set sql_select_limit=default; set sql_warnings=1; +set @save_table_open_cache=@@table_open_cache; set global table_open_cache=100; set default_storage_engine=myisam; set global thread_cache_size=100; @@ -752,7 +753,7 @@ table_open_cache 10 SELECT * FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME LIKE 'table_open_cache'; VARIABLE_NAME VARIABLE_VALUE TABLE_OPEN_CACHE 10 -SET GLOBAL table_open_cache=DEFAULT; +SET GLOBAL table_open_cache=@save_table_open_cache; set character_set_results=NULL; select ifnull(@@character_set_results,"really null"); ifnull(@@character_set_results,"really null") |