summaryrefslogtreecommitdiff
path: root/mysql-test/suite/galera
diff options
context:
space:
mode:
authorMonty <monty@mariadb.org>2015-12-10 12:39:54 +0200
committerMonty <monty@mariadb.org>2015-12-10 12:39:54 +0200
commit44b107da90a106c128dca278d04c68d804e51497 (patch)
tree023c5e15cd3fad5392377859de5a5655cb44c1cc /mysql-test/suite/galera
parent33f0cf71196d3d2869ccfcbf1c41a0a6709fe8df (diff)
downloadmariadb-git-44b107da90a106c128dca278d04c68d804e51497.tar.gz
Fixed a bug in galera + some failing galera tests
- Added missning setting of table->rpl_write_set in record_gtid(), required by galera - Removed output of WSREP_PATCH_VERSION from galera_defaults, as this can change over time - Limit galera_many_tables_pk and galera_many_tables_nopk to 900, as on many systems the default open table limit is 1024
Diffstat (limited to 'mysql-test/suite/galera')
-rw-r--r--mysql-test/suite/galera/r/galera_defaults.result4
-rw-r--r--mysql-test/suite/galera/r/galera_many_tables_nopk.result6
-rw-r--r--mysql-test/suite/galera/r/galera_many_tables_pk.result10
-rw-r--r--mysql-test/suite/galera/t/galera_defaults.test3
-rw-r--r--mysql-test/suite/galera/t/galera_many_tables_nopk.test26
-rw-r--r--mysql-test/suite/galera/t/galera_many_tables_pk.test24
6 files changed, 43 insertions, 30 deletions
diff --git a/mysql-test/suite/galera/r/galera_defaults.result b/mysql-test/suite/galera/r/galera_defaults.result
index cea97a8e047..a0fe1b622e6 100644
--- a/mysql-test/suite/galera/r/galera_defaults.result
+++ b/mysql-test/suite/galera/r/galera_defaults.result
@@ -12,7 +12,8 @@ AND VARIABLE_NAME NOT IN (
'WSREP_PROVIDER',
'WSREP_DATA_HOME_DIR',
'WSREP_NODE_INCOMING_ADDRESS',
-'WSREP_START_POSITION'
+'WSREP_START_POSITION',
+'WSREP_PATCH_VERSION'
)
ORDER BY VARIABLE_NAME;
VARIABLE_NAME VARIABLE_VALUE
@@ -37,7 +38,6 @@ WSREP_MYSQL_REPLICATION_BUNDLE 0
WSREP_NOTIFY_CMD
WSREP_ON ON
WSREP_OSU_METHOD TOI
-WSREP_PATCH_VERSION wsrep_25.10
WSREP_RECOVER OFF
WSREP_REPLICATE_MYISAM OFF
WSREP_RESTART_SLAVE OFF
diff --git a/mysql-test/suite/galera/r/galera_many_tables_nopk.result b/mysql-test/suite/galera/r/galera_many_tables_nopk.result
index 7a4f364730c..283905979ec 100644
--- a/mysql-test/suite/galera/r/galera_many_tables_nopk.result
+++ b/mysql-test/suite/galera/r/galera_many_tables_nopk.result
@@ -2,14 +2,14 @@ SET AUTOCOMMIT=OFF;
START TRANSACTION;
COMMIT;
CREATE TABLE sum_table (f1 INTEGER);
-SELECT SUM(f1) = 1000 FROM sum_table;
-SUM(f1) = 1000
+SELECT SUM(f1) = 900 FROM sum_table;
+SUM(f1) = 900
1
SET AUTOCOMMIT=OFF;
START TRANSACTION;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
-UPDATE t1000 SET f1 = 3;
+UPDATE t900 SET f1 = 3;
COMMIT;
COMMIT;
ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
diff --git a/mysql-test/suite/galera/r/galera_many_tables_pk.result b/mysql-test/suite/galera/r/galera_many_tables_pk.result
index 6b6899d979d..d0aa1694e85 100644
--- a/mysql-test/suite/galera/r/galera_many_tables_pk.result
+++ b/mysql-test/suite/galera/r/galera_many_tables_pk.result
@@ -1,18 +1,18 @@
-SELECT COUNT(*) = 1000 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'test' AND TABLE_NAME LIKE 't%';
-COUNT(*) = 1000
+SELECT COUNT(*) = 900 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'test' AND TABLE_NAME LIKE 't%';
+COUNT(*) = 900
1
SET AUTOCOMMIT=OFF;
START TRANSACTION;
COMMIT;
CREATE TABLE sum_table (f1 INTEGER);
-SELECT SUM(f1) = 1000 FROM sum_table;
-SUM(f1) = 1000
+SELECT SUM(f1) = 900 FROM sum_table;
+SUM(f1) = 900
1
SET AUTOCOMMIT=OFF;
START TRANSACTION;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
-UPDATE t1000 SET f1 = 3;
+UPDATE t900 SET f1 = 3;
COMMIT;
COMMIT;
ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
diff --git a/mysql-test/suite/galera/t/galera_defaults.test b/mysql-test/suite/galera/t/galera_defaults.test
index 1ef7c751859..1cbb19cc405 100644
--- a/mysql-test/suite/galera/t/galera_defaults.test
+++ b/mysql-test/suite/galera/t/galera_defaults.test
@@ -32,7 +32,8 @@ AND VARIABLE_NAME NOT IN (
'WSREP_PROVIDER',
'WSREP_DATA_HOME_DIR',
'WSREP_NODE_INCOMING_ADDRESS',
- 'WSREP_START_POSITION'
+ 'WSREP_START_POSITION',
+ 'WSREP_PATCH_VERSION'
)
ORDER BY VARIABLE_NAME;
diff --git a/mysql-test/suite/galera/t/galera_many_tables_nopk.test b/mysql-test/suite/galera/t/galera_many_tables_nopk.test
index 2496d145c93..98a65b7c660 100644
--- a/mysql-test/suite/galera/t/galera_many_tables_nopk.test
+++ b/mysql-test/suite/galera/t/galera_many_tables_nopk.test
@@ -2,17 +2,23 @@
--source include/galera_cluster.inc
--source include/have_innodb.inc
+if (!`SELECT @@open_files_limit >= 1024`){
+ skip Need at least an open file limit of 1000;
+}
+
#
-# This test forces 1K tables without a PK to participate in a single transaction
+# This test forces 900 tables without a PK to participate in a single
+# transaction. The reason for 900 is that some linux system has by default
+# a limit of 1024 open files / process
#
#
-# First, create 1K tables
+# First, create 900 tables
#
--connection node_1
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -22,7 +28,7 @@ while ($count)
--dec $count
}
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -33,13 +39,13 @@ while ($count)
}
#
-# Second, perform 1K updates
+# Second, perform 900 updates
#
SET AUTOCOMMIT=OFF;
START TRANSACTION;
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -57,7 +63,7 @@ COMMIT;
--connection node_2
CREATE TABLE sum_table (f1 INTEGER);
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -67,7 +73,7 @@ while ($count)
--dec $count
}
-SELECT SUM(f1) = 1000 FROM sum_table;
+SELECT SUM(f1) = 900 FROM sum_table;
#
# Fourth, create a deadlock
@@ -77,7 +83,7 @@ SELECT SUM(f1) = 1000 FROM sum_table;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -90,7 +96,7 @@ while ($count)
--connection node_2
SET AUTOCOMMIT=OFF;
START TRANSACTION;
-UPDATE t1000 SET f1 = 3;
+UPDATE t900 SET f1 = 3;
--connection node_1
COMMIT;
diff --git a/mysql-test/suite/galera/t/galera_many_tables_pk.test b/mysql-test/suite/galera/t/galera_many_tables_pk.test
index 886cb7c1a00..520459e3210 100644
--- a/mysql-test/suite/galera/t/galera_many_tables_pk.test
+++ b/mysql-test/suite/galera/t/galera_many_tables_pk.test
@@ -2,17 +2,23 @@
--source include/galera_cluster.inc
--source include/have_innodb.inc
+if (!`SELECT @@open_files_limit >= 1024`){
+ skip Need at least an open file limit of 1024;
+}
+
#
-# This test forces 1K tables with a PK to participate in a single transaction
+# This test forces 900 tables with a PK to participate in a single
+# transaction. The reason for 900 is that some linux system has by default
+# a limit of 1024 open files / process
#
#
-# First, create 1K tables and make sure the DDLs are all propagated
+# First, create 900 tables and make sure the DDLs are all propagated
#
--connection node_1
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -23,7 +29,7 @@ while ($count)
}
--connection node_2
-SELECT COUNT(*) = 1000 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'test' AND TABLE_NAME LIKE 't%';
+SELECT COUNT(*) = 900 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'test' AND TABLE_NAME LIKE 't%';
#
# Second, create a transaction that uses all those tables
@@ -33,7 +39,7 @@ SELECT COUNT(*) = 1000 FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'test
SET AUTOCOMMIT=OFF;
START TRANSACTION;
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -52,7 +58,7 @@ COMMIT;
--connection node_2
CREATE TABLE sum_table (f1 INTEGER);
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -62,7 +68,7 @@ while ($count)
--dec $count
}
-SELECT SUM(f1) = 1000 FROM sum_table;
+SELECT SUM(f1) = 900 FROM sum_table;
#
# Fourth, create a deadlock
@@ -72,7 +78,7 @@ SELECT SUM(f1) = 1000 FROM sum_table;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
---let $count = 1000
+--let $count = 900
while ($count)
{
--disable_query_log
@@ -85,7 +91,7 @@ while ($count)
--connection node_2
SET AUTOCOMMIT=OFF;
START TRANSACTION;
-UPDATE t1000 SET f1 = 3;
+UPDATE t900 SET f1 = 3;
--connection node_1
COMMIT;