Merged revision 3471, 3472 & 3473 from maria-5.5-galera.

This commit is contained in:
Nirbhay Choubey 2014-03-28 08:26:08 -04:00
commit 9d2e90f379
34 changed files with 624 additions and 11 deletions

View file

@ -98,6 +98,11 @@ static struct my_option my_long_options[] =
{0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}
};
void cleanup_and_exit(int exit_code)
{
my_end(0);
exit(exit_code);
}
static void usage(my_bool version)
{
@ -112,7 +117,7 @@ static void usage(my_bool version)
my_print_default_files(config_file);
my_print_variables(my_long_options);
printf("\nExample usage:\n%s --defaults-file=example.cnf client client-server mysql\n", my_progname);
exit(0);
cleanup_and_exit(0);
}
@ -125,7 +130,7 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)),
opt_defaults_file_used= 1;
break;
case 'n':
exit(0);
cleanup_and_exit(0);
case 'I':
case '?':
usage(0);
@ -174,7 +179,7 @@ int main(int argc, char **argv)
/* Check out the args */
if (get_options(&argc,&argv))
exit(1);
cleanup_and_exit(1);
nargs= argc + 1;
if (opt_mysqld)

View file

@ -0,0 +1,10 @@
# galera_cluster.inc
# ==================
#
# Description
# -----------
# Configure galera cluster with 2 nodes.
#
--let $galera_cluster_size = 2
--source include/galera_init.inc

View file

@ -0,0 +1,45 @@
# galera_connect.inc
# ==================
#
# Description
# -----------
# Open a connection to the specified server number ($galera_server_number).
# The connection itself would be identified by $galera_connection_name.
#
# Parameters
# ----------
# $galera_connection_name
# Name of the resulting connection.
#
# $galera_server_number
# Sequence number of the node in the galera cluster.
#
# $galera_debug
# Print debug information.
#
if (!$galera_connection_name)
{
--die ERROR IN TEST: $galera_connection_name must be set before sourcing include/galera_connect.inc
}
if (!$galera_server_number)
{
--die ERROR IN TEST: $galera_server_number must be set before sourcing include/galera_connect.inc
}
--let $_galera_port= \$NODE_MYPORT_$galera_server_number
if (!$_galera_port)
{
--echo Bug in test case: '\$NODE_MYPORT_$galera_server_number' not initialized. Check the test's .cfg file.
--die Not all NODE_MYPORT_* environment variables are setup correctly.
}
if ($galera_debug)
{
--echo connect($galera_connection_name,127.0.0.1,root,,test,$_galera_port,)
}
# Open a connection
--connect($galera_connection_name,127.0.0.1,root,,test,$_galera_port,)

View file

@ -0,0 +1,100 @@
# galera_diff.inc
# ===============
#
# Description
# -----------
# Compare the output of the given statement on all the nodes of the cluster.
#
# Parameters
# ----------
# $galera_diff_statement
# Statement for which the output would be compared.
#
# $galera_diff_database
# Database against which the above statement would be executed.
# (Default : test)
#
# $galera_diff_servers
# Comma separated list of servers to executed the diff statement on. If not
# set, a list of servers will be generated based on $galera_cluster_size.
#
# $galerra_debug
# Print debug information.
#
if (!$galera_diff_statement)
{
--die ERROR IN TEST: $galera_diff_statement must be set before sourcing include/galera_diff.inc
}
--let $_galera_diff_database = $galera_diff_database
if (!$_galera_diff_database)
{
--let $_galera_diff_database = test
}
--let $_galera_diff_servers= $galera_diff_servers
if (!$_galera_diff_servers)
{
--let $_i= $galera_cluster_size
--let $_galera_diff_servers=
while ($_i)
{
--let $_galera_diff_servers= $_i,$_galera_diff_servers
--dec $_i
}
}
if ($galera_debug)
{
--echo \$galera_diff_servers= '$_galera_diff_servers'
}
if (!$galera_debug)
{
--disable_query_log
}
# Generate file containing $galera_diff_statement. We don't pass the
# statement on the command line, because it would be subject to shell
# substitutions.
--let $write_to_file= GENERATE
--let $write_var= $galera_diff_statement
--source include/write_var_to_file.inc
--let $_galera_diff_statement_file= $write_to_file
if (!$galera_debug)
{
--enable_query_log
}
# Compare all servers.
--let $_galera_diff_first= 1
while ($_galera_diff_servers)
{
# Set $_galera_diff_server_i to the first number in the list
--let $_galera_diff_server_i= `SELECT SUBSTRING_INDEX('$_galera_diff_servers', ',', 1)`
# Remove $_galera_diff_server_i from the list
--let $_galera_diff_servers= `SELECT SUBSTRING('$_galera_diff_servers', LENGTH('$_galera_diff_server_i') + 2)`
# Execute statement
--let $_galera_diff_file= $MYSQLTEST_VARDIR/tmp/_galera_diff_server-$_galera_diff_server_i.tmp
--exec $MYSQL --defaults-group-suffix=.$_galera_diff_server_i $_galera_diff_database < $_galera_diff_statement_file > $_galera_diff_file
# Compare
if (!$_galera_diff_first)
{
if ($galera_debug)
{
--echo diffing $_galera_diff_file and $_galera_diff_prev_file
}
--diff_files $_galera_diff_file $_galera_diff_prev_file
--remove_file $_galera_diff_prev_file
}
--let $_galera_diff_prev_file= $_galera_diff_file
--let $_galera_diff_first= 0
}
# Cleanup
--remove_file $_galera_diff_prev_file
--remove_file $_galera_diff_statement_file

View file

@ -0,0 +1,25 @@
# galera_end.inc
# ==============
#
# Description
# -----------
# Closes the connections opened via include/galera_init.inc
#
# Parameters
# ----------
# $galera_cluster_size
# Number of nodes in the cluster.
#
--let $_galera_node= $galera_cluster_size
while ($_galera_node)
{
if ($galera_debug)
{
--echo Disconnecting node_$_galera_node
}
--disconnect node_$_galera_node
--dec $_galera_node
}

View file

@ -0,0 +1,26 @@
# galera_init.inc
# ===============
#
# Description
# -----------
# Set up a Galera cluster with $wsrep_cluster_size nodes.
#
# Parameters
# ----------
# $galera_cluster_size
# Number of nodes in the cluster.
#
--source include/have_wsrep_enabled.inc
--let $_galera_node= $galera_cluster_size
while ($_galera_node)
{
--let $galera_connection_name= node_$_galera_node
--let $galera_server_number= $_galera_node
--source include/galera_connect.inc
--dec $_galera_node
}

View file

@ -1,4 +1,8 @@
-- require r/have_wsrep.require
disable_query_log;
show variables like 'wsrep_on';
enable_query_log;
# To be used in a test which requires server to be compiled with wsrep support
# (-DWITH_WSREP=ON) and wsrep plugin is ACTIVE.
if (`SELECT COUNT(*)=0 FROM INFORMATION_SCHEMA.PLUGINS WHERE PLUGIN_NAME = 'wsrep' AND PLUGIN_STATUS='ACTIVE'`)
{
--skip Test required wsrep plugin.
}

View file

@ -0,0 +1,9 @@
# To be used in a test which requires wsrep plugin to be ACTIVE and enabled
# (i.e. wsrep_on=ON). It includes have_wsrep.inc.
--source include/have_wsrep.inc
--require r/have_wsrep.require
disable_query_log;
SHOW VARIABLES LIKE 'wsrep_on';
enable_query_log;

View file

@ -226,6 +226,14 @@ INSERT INTO global_suppressions VALUES
("Slave I/O: Notifying master by SET @master_binlog_checksum= @@global.binlog_checksum failed with error.*"),
("Slave I/O: Setting master-side filtering of @@skip_replication failed with error:.*"),
("Slave I/O: Setting @mariadb_slave_capability failed with error:.*"),
/*
Galera-related warnings.
*/
("WSREP: Could not open saved state file for reading: .*"),
("WSREP: last inactive check more than .* skipping check"),
("WSREP: Gap in state sequence. Need state transfer."),
("WSREP: Failed to prepare for incremental state transfer: .*"),
("THE_LAST_SUPPRESSION")||

View file

@ -0,0 +1,7 @@
# To be used in a test which should be skipped if server is compiled with wsrep
# support (-DWITH_WSREP=ON) and wsrep plugin is ACTIVE.
-- require r/not_wsrep.require
disable_query_log;
SELECT VERSION() LIKE '%wsrep%' AS 'HAVE_WSREP';
enable_query_log;

View file

@ -862,6 +862,8 @@ sub collect_one_test_case {
# Suite has no config, autodetect which one to use
if ($tinfo->{rpl_test}) {
$config= "suite/rpl/my.cnf";
} elsif ($tinfo->{galera_test}) {
$config= "suite/galera/my.cnf";
} else {
$config= "include/default_my.cnf";
}
@ -982,6 +984,7 @@ my $tags_map= {'big_test' => ['big_test', 1],
'master-slave' => ['rpl_test', 1],
'ndb_master-slave' => ['rpl_test', 1, 'ndb_test', 1],
'long_test' => ['long_test', 1],
'galera_init' => ['galera_test', 1],
};
my $tags_regex_string= join('|', keys %$tags_map);
my $tags_regex= qr:include/($tags_regex_string)\.inc:o;

View file

@ -4832,6 +4832,9 @@ sub extract_warning_lines ($$) {
qr|Plugin 'FEEDBACK' registration as a INFORMATION SCHEMA failed|,
qr|'log-bin-use-v1-row-events' is MySQL 5.6 compatible option|,
qr|InnoDB: Setting thread \d+ nice to \d+ failed, current nice \d+, errno 13|, # setpriority() fails under valgrind
# Galera-related warnings.
qr|WSREP:.*down context.*|,
qr|WSREP: Failed to send state UUID:.*|,
);
my $matched_lines= [];

View file

@ -0,0 +1,2 @@
HAVE_WSREP
0

View file

@ -0,0 +1,21 @@
# Use default setting for mysqld processes
!include include/default_mysqld.cnf
[mysqld.1]
binlog-format=row
wsrep_provider=/usr/lib/libgalera_smm.so
wsrep_cluster_address='gcomm://'
[mysqld.2]
binlog-format=row
wsrep_provider=/usr/lib/libgalera_smm.so
wsrep_cluster_address='gcomm://127.0.0.1:4567'
wsrep_provider_options='gmcast.listen_addr=tcp://127.0.0.1:4568'
[ENV]
NODE_MYPORT_1= @mysqld.1.port
NODE_MYSOCK_1= @mysqld.1.socket
NODE_MYPORT_2= @mysqld.2.port
NODE_MYSOCK_2= @mysqld.2.socket

View file

@ -0,0 +1 @@
!include galera_2nodes.cnf

View file

@ -0,0 +1,30 @@
USE test;
CREATE TABLE t1(c1 INT PRIMARY KEY) ENGINE=INNODB;
INSERT INTO t1 VALUES (1), (2), (3), (4), (5);
SELECT * FROM t1;
c1
1
2
3
4
5
# On node_1
SELECT * FROM test.t1;
c1
1
2
3
4
5
# On node_2
SELECT * FROM test.t1;
c1
1
2
3
4
5
DROP TABLE t1;
# End of test

View file

@ -0,0 +1,47 @@
#
# MDEV#5552 Deadlock when inserting NULL column value in column with
# UNIQUE index
#
USE test;
# On node_1
CREATE TABLE t1(c1 INT DEFAULT NULL, UNIQUE KEY c1(c1)) ENGINE=INNODB;
INSERT INTO t1 VALUES (NULL);
INSERT INTO t1 VALUES (NULL);
SELECT * FROM test.t1;
c1
NULL
NULL
# On node_2
SELECT * FROM test.t1;
c1
NULL
NULL
# On node_1
INSERT INTO t1 VALUES (1);
UPDATE t1 SET c1=NULL WHERE c1=1;
SELECT * FROM test.t1;
c1
NULL
NULL
NULL
# On node_2
SELECT * FROM test.t1;
c1
NULL
NULL
NULL
# On node_1
DELETE FROM t1 WHERE c1<=>NULL;
SELECT * FROM test.t1;
c1
# On node_2
SELECT * FROM test.t1;
c1
DROP TABLE t1;
# End of test

View file

@ -0,0 +1,26 @@
--source include/galera_cluster.inc
--source include/have_innodb.inc
USE test;
CREATE TABLE t1(c1 INT PRIMARY KEY) ENGINE=INNODB;
INSERT INTO t1 VALUES (1), (2), (3), (4), (5);
SELECT * FROM t1;
--echo
--echo # On node_1
--connection node_1
SELECT * FROM test.t1;
--echo
--echo # On node_2
--connection node_2
SELECT * FROM test.t1;
--let $galera_diff_statement = SELECT * FROM t1
--source include/galera_diff.inc
# Cleanup
DROP TABLE t1;
--source include/galera_end.inc
--echo # End of test

View file

@ -0,0 +1,54 @@
--source include/galera_cluster.inc
--source include/have_innodb.inc
--echo #
--echo # MDEV#5552 Deadlock when inserting NULL column value in column with
--echo # UNIQUE index
--echo #
USE test;
--echo
--echo # On node_1
--connection node_1
CREATE TABLE t1(c1 INT DEFAULT NULL, UNIQUE KEY c1(c1)) ENGINE=INNODB;
INSERT INTO t1 VALUES (NULL);
INSERT INTO t1 VALUES (NULL);
SELECT * FROM test.t1;
--echo
--echo # On node_2
--connection node_2
SELECT * FROM test.t1;
--echo
--echo # On node_1
--connection node_1
INSERT INTO t1 VALUES (1);
UPDATE t1 SET c1=NULL WHERE c1=1;
SELECT * FROM test.t1;
--echo
--echo # On node_2
--connection node_2
SELECT * FROM test.t1;
--echo
--echo # On node_1
--connection node_1
DELETE FROM t1 WHERE c1<=>NULL;
SELECT * FROM test.t1;
--echo
--echo # On node_2
--connection node_2
SELECT * FROM test.t1;
--let $galera_diff_statement = SELECT * FROM t1
--source include/galera_diff.inc
# Cleanup
DROP TABLE t1;
--source include/galera_end.inc
--echo # End of test

View file

@ -0,0 +1,7 @@
* 'wsrep' suite is designated for tests which do not require a multi-node
galera cluster.
* As these tests are specific to wsrep-related functionalities, they must skip
on server built without wsrep patch (vanilla). (-DWITH_WSREP=OFF)
See : include/have_wsrep.inc, include/have_wsrep_enabled.inc, not_wsrep.inc

View file

@ -1,3 +1,5 @@
call mtr.add_suppression("WSREP: cannot get fake InnoDB transaction ID");
call mtr.add_suppression("WSREP: Could not open saved state file for reading:.*");
SHOW VARIABLES LIKE 'binlog_format';
Variable_name Value
binlog_format ROW

View file

@ -0,0 +1,70 @@
#
# MDEV-5226 mysql_tzinfo_to_sql errors with tzdata 2013f and above
#
# Verbose run
SET GLOBAL wsrep_replicate_myisam= ON;
TRUNCATE TABLE time_zone;
TRUNCATE TABLE time_zone_name;
TRUNCATE TABLE time_zone_transition;
TRUNCATE TABLE time_zone_transition_type;
INSERT INTO time_zone (Use_leap_seconds) VALUES ('N');
SET @time_zone_id= LAST_INSERT_ID();
INSERT INTO time_zone_name (Name, Time_zone_id) VALUES ('GMT', @time_zone_id);
INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Is_DST, Abbreviation) VALUES
(@time_zone_id, 0, 0, 0, 'GMT')
;
Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/garbage' as time zone. Skipping it.
Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/ignored.tab' as time zone. Skipping it.
INSERT INTO time_zone (Use_leap_seconds) VALUES ('N');
SET @time_zone_id= LAST_INSERT_ID();
INSERT INTO time_zone_name (Name, Time_zone_id) VALUES ('posix/GMT', @time_zone_id);
INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Is_DST, Abbreviation) VALUES
(@time_zone_id, 0, 0, 0, 'GMT')
;
Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/posix/garbage' as time zone. Skipping it.
Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/posix/ignored.tab' as time zone. Skipping it.
Warning: Skipping directory 'MYSQLTEST_VARDIR/zoneinfo/posix/posix': to avoid infinite symlink recursion.
ALTER TABLE time_zone_transition ORDER BY Time_zone_id, Transition_time;
ALTER TABLE time_zone_transition_type ORDER BY Time_zone_id, Transition_type_id;
SET GLOBAL wsrep_replicate_myisam= OFF;
# Silent run
SET GLOBAL wsrep_replicate_myisam= ON;
TRUNCATE TABLE time_zone;
TRUNCATE TABLE time_zone_name;
TRUNCATE TABLE time_zone_transition;
TRUNCATE TABLE time_zone_transition_type;
INSERT INTO time_zone (Use_leap_seconds) VALUES ('N');
SET @time_zone_id= LAST_INSERT_ID();
INSERT INTO time_zone_name (Name, Time_zone_id) VALUES ('GMT', @time_zone_id);
INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Is_DST, Abbreviation) VALUES
(@time_zone_id, 0, 0, 0, 'GMT')
;
Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/garbage' as time zone. Skipping it.
INSERT INTO time_zone (Use_leap_seconds) VALUES ('N');
SET @time_zone_id= LAST_INSERT_ID();
INSERT INTO time_zone_name (Name, Time_zone_id) VALUES ('posix/GMT', @time_zone_id);
INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Is_DST, Abbreviation) VALUES
(@time_zone_id, 0, 0, 0, 'GMT')
;
Warning: Unable to load 'MYSQLTEST_VARDIR/zoneinfo/posix/garbage' as time zone. Skipping it.
ALTER TABLE time_zone_transition ORDER BY Time_zone_id, Transition_time;
ALTER TABLE time_zone_transition_type ORDER BY Time_zone_id, Transition_type_id;
SET GLOBAL wsrep_replicate_myisam= OFF;
#
# Testing with explicit timezonefile
#
SET GLOBAL wsrep_replicate_myisam= ON;
INSERT INTO time_zone (Use_leap_seconds) VALUES ('N');
SET @time_zone_id= LAST_INSERT_ID();
INSERT INTO time_zone_name (Name, Time_zone_id) VALUES ('XXX', @time_zone_id);
INSERT INTO time_zone_transition_type (Time_zone_id, Transition_type_id, Offset, Is_DST, Abbreviation) VALUES
(@time_zone_id, 0, 0, 0, 'GMT')
;
SET GLOBAL wsrep_replicate_myisam= OFF;
#
# Testing --leap
#
SET GLOBAL wsrep_replicate_myisam= ON;
TRUNCATE TABLE time_zone_leap_second;
ALTER TABLE time_zone_leap_second ORDER BY Transition_time;
SET GLOBAL wsrep_replicate_myisam= OFF;

View file

@ -0,0 +1,8 @@
#
# MDEV#5687: Maria doesn't shutdown following upgrade to 5.5.35-galera
#
SELECT @@GLOBAL.thread_handling;
@@GLOBAL.thread_handling
pool-of-threads
# End of test.

View file

@ -1,3 +1,16 @@
# MDEV#5534: mysql_tzinfo_to_sql generates wrong query
#
# Testing wsrep_replicate_myisam variable.
SELECT @@session.wsrep_replicate_myisam;
ERROR HY000: Variable 'wsrep_replicate_myisam' is a GLOBAL variable
SELECT @@global.wsrep_replicate_myisam;
@@global.wsrep_replicate_myisam
0
SET SESSION wsrep_replicate_myisam= ON;
ERROR HY000: Variable 'wsrep_replicate_myisam' is a GLOBAL variable and should be set with SET GLOBAL
SET GLOBAL wsrep_replicate_myisam= ON;
SET GLOBAL wsrep_replicate_myisam= OFF;
#
# MDEV#5790: SHOW GLOBAL STATUS LIKE does not show the correct list of
# variables when using "_"

View file

@ -1,8 +1,11 @@
--source include/have_wsrep.inc
--source include/have_wsrep_enabled.inc
--source include/have_binlog_format_row.inc
#
# MDEV-4227: Galera server should stop crashing on setting binlog_format STATEMENT
#
call mtr.add_suppression("WSREP: cannot get fake InnoDB transaction ID");
call mtr.add_suppression("WSREP: Could not open saved state file for reading:.*");
SHOW VARIABLES LIKE 'binlog_format';
-- error ER_WRONG_VALUE_FOR_VAR
SET binlog_format=STATEMENT;

View file

@ -0,0 +1,40 @@
--source include/have_wsrep.inc
--source include/have_symlink.inc
--source include/not_windows.inc
--echo #
--echo # MDEV-5226 mysql_tzinfo_to_sql errors with tzdata 2013f and above
--echo #
--exec mkdir $MYSQLTEST_VARDIR/zoneinfo
--exec ln -s $MYSQLTEST_VARDIR/zoneinfo $MYSQLTEST_VARDIR/zoneinfo/posix
--copy_file std_data/zoneinfo/GMT $MYSQLTEST_VARDIR/zoneinfo/GMT
--copy_file std_data/words.dat $MYSQLTEST_VARDIR/zoneinfo/garbage
--copy_file std_data/words.dat $MYSQLTEST_VARDIR/zoneinfo/ignored.tab
--echo # Verbose run
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
--exec $MYSQL_TZINFO_TO_SQL --verbose $MYSQLTEST_VARDIR/zoneinfo 2>&1
--echo # Silent run
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
--exec $MYSQL_TZINFO_TO_SQL $MYSQLTEST_VARDIR/zoneinfo 2>&1
--echo #
--echo # Testing with explicit timezonefile
--echo #
--replace_result $MYSQLTEST_VARDIR MYSQLTEST_VARDIR
--exec $MYSQL_TZINFO_TO_SQL $MYSQLTEST_VARDIR/zoneinfo/GMT XXX 2>&1
--echo #
--echo # Testing --leap
--echo #
--exec $MYSQL_TZINFO_TO_SQL --leap $MYSQLTEST_VARDIR/zoneinfo/GMT 2>&1
#
# Cleanup
#
--exec rm -rf $MYSQLTEST_VARDIR/zoneinfo

View file

@ -0,0 +1 @@
--binlog-format=row --innodb_autoinc_lock_mode=2 --innodb_locks_unsafe_for_binlog=1 --wsrep-provider=/usr/lib/galera/libgalera_smm.so --wsrep-cluster-address=gcomm:// --thread_handling=pool-of-threads

View file

@ -0,0 +1,11 @@
--source include/have_wsrep.inc
--echo
--echo #
--echo # MDEV#5687: Maria doesn't shutdown following upgrade to 5.5.35-galera
--echo #
# Note: This test is to ensure that server shuts down properly.
SELECT @@GLOBAL.thread_handling;
--echo # End of test.

View file

@ -1,3 +1,4 @@
--source include/have_wsrep.inc
--source include/have_innodb.inc
--echo #

View file

@ -1,5 +1,21 @@
--source include/have_wsrep.inc
--echo
--echo # MDEV#5534: mysql_tzinfo_to_sql generates wrong query
--echo #
--echo # Testing wsrep_replicate_myisam variable.
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
SELECT @@session.wsrep_replicate_myisam;
SELECT @@global.wsrep_replicate_myisam;
--error ER_GLOBAL_VARIABLE
SET SESSION wsrep_replicate_myisam= ON;
SET GLOBAL wsrep_replicate_myisam= ON;
# Reset it back.
SET GLOBAL wsrep_replicate_myisam= OFF;
--echo #
--echo # MDEV#5790: SHOW GLOBAL STATUS LIKE does not show the correct list of
--echo # variables when using "_"
@ -18,4 +34,3 @@ SHOW VARIABLES LIKE 'wsrep_%';
SHOW VARIABLES LIKE 'x';
--echo # End of test.

View file

@ -1,6 +1,11 @@
--source include/have_symlink.inc
--source include/not_windows.inc
# Note: The output of mysql_tzinfo_to_sql is different if server is compiled
# with wsrep. Hence a copy of this test has been placed under wsrep suite with
# the updated result. (lp:1161432)
--source include/not_wsrep.inc
--echo #
--echo # MDEV-5226 mysql_tzinfo_to_sql errors with tzdata 2013f and above
--echo #

View file

@ -6218,7 +6218,7 @@ void ha_wsrep_fake_trx_id(THD *thd)
}
else
{
WSREP_WARN("cannot get get fake InnoDB transaction ID");
WSREP_WARN("cannot get fake InnoDB transaction ID");
}
DBUG_VOID_RETURN;

View file

@ -2055,6 +2055,10 @@ extern "C" void unireg_abort(int exit_code)
wsrep_close_threads(thd); /* this won't close all threads */
sleep(1); /* so give some time to exit for those which can */
WSREP_INFO("Some threads may fail to exit.");
/* In bootstrap mode we deinitialize wsrep here. */
if (opt_bootstrap && wsrep_inited)
wsrep_deinit();
}
#endif // WITH_WSREP
clean_up(!opt_abort && (exit_code || !opt_bootstrap)); /* purecov: inspected */

View file

@ -2709,8 +2709,10 @@ main(int argc, char **argv)
return 1;
}
#ifdef WITH_WSREP
// Replicate MyISAM DDL for this session, cf. lp:1161432
printf("SET SESSION wsrep_replicate_myisam=ON;\n");
printf("SET GLOBAL wsrep_replicate_myisam= ON;\n");
#endif /* WITH_WSREP */
if (argc == 1 && !opt_leap)
{
@ -2759,6 +2761,11 @@ main(int argc, char **argv)
free_root(&tz_storage, MYF(0));
}
#ifdef WITH_WSREP
// Reset wsrep_replicate_myisam. lp:1161432
printf("SET GLOBAL wsrep_replicate_myisam= OFF;\n");
#endif /* WITH_WSREP */
free_defaults(default_argv);
my_end(0);
return 0;