From abcd23add20276e4996773f578e77d5733e1b582 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Mon, 4 Sep 2023 15:32:36 +0200 Subject: [PATCH] MDEV-31857 enable --ssl-verify-server-cert by default in the internal client enable ssl + ssl_verify_server_cert in the internal client too * fix replication tests to disable master_ssl_verify_server_cert because accounts are passwordless - except rpl.rpl_ssl1 * fix federated/federatedx/connect to disable SSL_VERIFY_SERVER_CERT because they cannot configure an ssl connection * fix spider to disable ssl_verify_server_cert, if configuration says so, as spider _can_ configure an ssl connection * memory leak in embedded test-connect --- include/sql_common.h | 2 +- mysql-test/include/check-testcase.test | 2 +- mysql-test/include/rpl_change_topology.inc | 4 ++-- mysql-test/main/ps_change_master.result | 2 +- mysql-test/main/ps_change_master.test | 2 +- .../binlog_encryption/multisource.result | 4 +++- .../suite/binlog_encryption/rpl_ssl.result | 2 +- .../suite/engines/funcs/r/rpl_000010.result | 1 + .../funcs/r/rpl_dual_pos_advance.result | 3 ++- .../engines/funcs/r/rpl_flushlog_loop.result | 4 ++-- .../engines/funcs/t/rpl_dual_pos_advance.test | 3 ++- .../engines/funcs/t/rpl_flushlog_loop.test | 4 ++-- .../r/galera_query_cache_invalidate.result | 2 +- mysql-test/suite/galera/t/MDEV-28053.test | 2 +- mysql-test/suite/galera/t/MDEV-6860.test | 2 +- .../suite/galera/t/galera_as_master.test | 2 +- .../galera/t/galera_as_master_large.test | 2 +- .../suite/galera/t/galera_as_slave.test | 2 +- .../galera/t/galera_as_slave_autoinc.test | 2 +- .../suite/galera/t/galera_as_slave_gtid.inc | 2 +- .../galera/t/galera_as_slave_gtid_myisam.test | 2 +- .../galera/t/galera_as_slave_nonprim.test | 2 +- .../suite/galera/t/galera_gtid_slave.test | 2 +- .../galera/t/galera_gtid_slave_sst_rsync.test | 2 +- .../t/galera_query_cache_invalidate.test | 2 +- .../mariabackup/slave_provision_nolock.result | 1 + .../mariabackup/slave_provision_nolock.test | 1 + mysql-test/suite/multi_source/gtid.result | 12 +++++----- mysql-test/suite/multi_source/gtid.test | 12 +++++----- .../gtid_ignore_duplicates.result | 14 ++++++------ .../multi_source/gtid_ignore_duplicates.test | 14 ++++++------ .../suite/multi_source/gtid_slave_pos.result | 4 ++-- .../suite/multi_source/gtid_slave_pos.test | 4 ++-- .../suite/multi_source/info_logs.result | 14 ++++++------ mysql-test/suite/multi_source/info_logs.test | 6 ++--- .../suite/multi_source/load_data.result | 4 ++-- mysql-test/suite/multi_source/load_data.test | 4 ++-- .../suite/multi_source/mdev-8874.result | 12 +++++----- mysql-test/suite/multi_source/mdev-8874.test | 12 +++++----- .../suite/multi_source/mdev-9544.result | 6 ++--- mysql-test/suite/multi_source/mdev-9544.test | 6 ++--- .../suite/multi_source/multi_parallel.result | 4 ++-- .../suite/multi_source/multi_parallel.test | 4 ++-- .../multi_source_slave_alias_replica.result | 8 +++---- .../multi_source_slave_alias_replica.test | 4 ++-- .../suite/multi_source/multisource.result | 4 +++- .../multisource_for_channel.result | 4 ++-- .../multi_source/multisource_for_channel.test | 4 ++-- .../suite/multi_source/relaylog_events.result | 2 +- .../suite/multi_source/relaylog_events.test | 2 +- .../replicate_rewrite_db_dynamic.result | 4 ++-- .../replicate_rewrite_db_dynamic.test | 4 ++-- .../suite/multi_source/reset_slave.result | 6 ++--- .../suite/multi_source/reset_slave.test | 2 +- mysql-test/suite/multi_source/simple.result | 22 +++++++++---------- mysql-test/suite/multi_source/simple.test | 4 ++-- .../suite/multi_source/skip_counter.result | 4 ++-- .../suite/multi_source/skip_counter.test | 4 ++-- .../suite/multi_source/status_vars.result | 4 ++-- .../suite/multi_source/status_vars.test | 4 ++-- mysql-test/suite/rpl/include/multisource.inc | 4 +++- .../rpl/include/rpl_change_master_demote.inc | 2 +- .../rpl/r/grant_replication_slave.result | 2 +- mysql-test/suite/rpl/r/rpl_000010.result | 1 + .../rpl/r/rpl_change_master_demote.result | 18 +++++++-------- .../suite/rpl/r/rpl_circular_semi_sync.result | 2 +- mysql-test/suite/rpl/r/rpl_connection.result | 2 +- .../rpl/r/rpl_gtid_master_promote.result | 3 ++- .../suite/rpl/r/rpl_gtid_mdev4473.result | 3 ++- .../suite/rpl/r/rpl_gtid_mdev4485.result | 2 +- .../suite/rpl/r/rpl_gtid_mdev4820.result | 2 +- .../suite/rpl/r/rpl_gtid_nobinlog.result | 6 ++--- mysql-test/suite/rpl/r/rpl_heartbeat.result | 2 +- .../suite/rpl/r/rpl_heartbeat_ssl.result | 2 +- .../suite/rpl/r/rpl_ipv4_as_ipv6.result | 2 +- mysql-test/suite/rpl/r/rpl_ipv6.result | 2 +- .../suite/rpl/r/rpl_master_pos_wait.result | 2 +- ...perfschema_applier_status_by_worker.result | 2 +- .../r/rpl_perfschema_connect_config.result | 2 +- .../rpl/r/rpl_rewrite_db_sys_vars.result | 2 +- mysql-test/suite/rpl/r/rpl_rotate_logs.result | 2 +- .../rpl/r/rpl_semi_sync_fail_over.result | 6 ++--- .../rpl/r/rpl_semisync_ali_issues.result | 2 -- .../r/rpl_set_statement_default_master.result | 4 +++- .../suite/rpl/r/rpl_show_slave_hosts.result | 2 +- .../rpl/r/rpl_slave_shutdown_mdev20821.result | 2 +- mysql-test/suite/rpl/r/rpl_ssl.result | 2 +- mysql-test/suite/rpl/r/rpl_ssl1.result | 4 ++-- .../r/rpl_start_alter_restart_slave.result | 4 ++-- .../rpl/r/rpl_upgrade_master_info.result | 2 +- .../r/show_status_stop_slave_race-7126.result | 2 +- .../suite/rpl/t/grant_replication_slave.test | 2 +- mysql-test/suite/rpl/t/rpl_000010.test | 1 + .../suite/rpl/t/rpl_circular_semi_sync.test | 2 +- mysql-test/suite/rpl/t/rpl_connection.test | 2 +- .../suite/rpl/t/rpl_gtid_master_promote.test | 3 ++- mysql-test/suite/rpl/t/rpl_gtid_mdev4473.test | 3 ++- mysql-test/suite/rpl/t/rpl_gtid_mdev4485.test | 2 +- mysql-test/suite/rpl/t/rpl_gtid_mdev4820.test | 2 +- mysql-test/suite/rpl/t/rpl_gtid_nobinlog.test | 6 ++--- mysql-test/suite/rpl/t/rpl_heartbeat.test | 2 +- mysql-test/suite/rpl/t/rpl_heartbeat_ssl.test | 2 +- mysql-test/suite/rpl/t/rpl_ipv4_as_ipv6.test | 2 +- mysql-test/suite/rpl/t/rpl_ipv6.test | 2 +- .../suite/rpl/t/rpl_master_pos_wait.test | 2 +- ...l_perfschema_applier_status_by_worker.test | 2 +- .../rpl/t/rpl_perfschema_connect_config.test | 2 +- .../suite/rpl/t/rpl_rewrite_db_sys_vars.test | 2 +- mysql-test/suite/rpl/t/rpl_rotate_logs.test | 2 +- .../suite/rpl/t/rpl_semi_sync_crash.inc | 2 +- .../suite/rpl/t/rpl_semisync_ali_issues.test | 1 - .../t/rpl_set_statement_default_master.test | 4 +++- .../suite/rpl/t/rpl_show_slave_hosts.test | 2 +- .../rpl/t/rpl_slave_shutdown_mdev20821.test | 2 +- mysql-test/suite/rpl/t/rpl_ssl.test | 2 +- mysql-test/suite/rpl/t/rpl_ssl1.test | 4 ++-- mysql-test/suite/rpl/t/rpl_start_alter_7.test | 4 ++-- mysql-test/suite/rpl/t/rpl_start_alter_8.test | 4 ++-- .../rpl/t/rpl_start_alter_mysqlbinlog_2.test | 4 ++-- .../rpl/t/rpl_start_alter_restart_slave.test | 6 ++--- .../suite/rpl/t/rpl_upgrade_master_info.test | 2 +- .../t/show_status_stop_slave_race-7126.test | 2 +- sql-common/client.c | 18 +++++++-------- sql/rpl_mi.cc | 2 +- storage/connect/myconn.cpp | 5 +++-- storage/federated/ha_federated.cc | 13 +++++------ storage/federatedx/federatedx_io_mysql.cc | 13 +++++------ storage/federatedx/ha_federatedx.cc | 2 ++ .../spider/bg/t/slave_test_init.inc | 3 ++- .../mysql-test/spider/t/slave_test_init.inc | 3 ++- storage/spider/spd_db_mysql.cc | 10 ++++----- unittest/embedded/test-connect.cc | 12 +++++----- 132 files changed, 276 insertions(+), 259 deletions(-) diff --git a/include/sql_common.h b/include/sql_common.h index 2a79261c6e8..1d33f38197b 100644 --- a/include/sql_common.h +++ b/include/sql_common.h @@ -41,7 +41,7 @@ struct st_mysql_options_extention { uint proc_info_length); HASH connection_attributes; size_t connection_attributes_length; - my_bool tls_verify_server_cert; + my_bool tls_allow_invalid_server_cert; }; typedef struct st_mysql_methods diff --git a/mysql-test/include/check-testcase.test b/mysql-test/include/check-testcase.test index 1038ff30c11..eea0aca6e84 100644 --- a/mysql-test/include/check-testcase.test +++ b/mysql-test/include/check-testcase.test @@ -47,7 +47,7 @@ if ($tmp) --echo Until_Condition # --echo Until_Log_File # --echo Until_Log_Pos # - --echo Master_SSL_Allowed No + --echo Master_SSL_Allowed Yes --echo Master_SSL_CA_File --echo Master_SSL_CA_Path --echo Master_SSL_Cert diff --git a/mysql-test/include/rpl_change_topology.inc b/mysql-test/include/rpl_change_topology.inc index b63700b059b..eb8a6795615 100644 --- a/mysql-test/include/rpl_change_topology.inc +++ b/mysql-test/include/rpl_change_topology.inc @@ -235,11 +235,11 @@ if (!$rpl_skip_change_master) } if ($rpl_master_log_file) { - eval CHANGE MASTER TO MASTER_HOST = '127.0.0.1', MASTER_PORT = $_rpl_port, MASTER_USER = 'root', MASTER_LOG_FILE = '$_rpl_master_log_file'$_rpl_master_log_pos, MASTER_CONNECT_RETRY = 1, MASTER_USE_GTID=NO; + eval CHANGE MASTER TO MASTER_HOST = '127.0.0.1', MASTER_PORT = $_rpl_port, MASTER_USER = 'root', MASTER_LOG_FILE = '$_rpl_master_log_file'$_rpl_master_log_pos, MASTER_CONNECT_RETRY = 1, MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_USE_GTID=NO; } if (!$rpl_master_log_file) { - eval CHANGE MASTER TO MASTER_HOST = '127.0.0.1', MASTER_PORT = $_rpl_port, MASTER_USER = 'root', MASTER_CONNECT_RETRY=1; + eval CHANGE MASTER TO MASTER_HOST = '127.0.0.1', MASTER_PORT = $_rpl_port, MASTER_USER = 'root', MASTER_CONNECT_RETRY=1, MASTER_SSL_VERIFY_SERVER_CERT=0; } } if ($_rpl_master == '') diff --git a/mysql-test/main/ps_change_master.result b/mysql-test/main/ps_change_master.result index 25069a537a5..4c97715b382 100644 --- a/mysql-test/main/ps_change_master.result +++ b/mysql-test/main/ps_change_master.result @@ -18,5 +18,5 @@ EXECUTE stmt; DEALLOCATE PREPARE stmt; # Master_Host : host2 # Master_User : user2 -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; # End of test diff --git a/mysql-test/main/ps_change_master.test b/mysql-test/main/ps_change_master.test index d756b8cd4fb..19040917bde 100644 --- a/mysql-test/main/ps_change_master.test +++ b/mysql-test/main/ps_change_master.test @@ -40,6 +40,6 @@ let $master_user= query_get_value(SHOW SLAVE STATUS, Master_User, 1); # Reset -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; --echo # End of test diff --git a/mysql-test/suite/binlog_encryption/multisource.result b/mysql-test/suite/binlog_encryption/multisource.result index 4b53b4653cd..ca420f9a9b6 100644 --- a/mysql-test/suite/binlog_encryption/multisource.result +++ b/mysql-test/suite/binlog_encryption/multisource.result @@ -6,7 +6,8 @@ ERROR HY000: Incorrect arguments to MASTER_HOST change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', +master_ssl_verify_server_cert=0; start slave 'master1'; set default_master_connection = 'master1'; include/wait_for_slave_to_start.inc @@ -100,6 +101,7 @@ change master to master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', +master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/binlog_encryption/rpl_ssl.result b/mysql-test/suite/binlog_encryption/rpl_ssl.result index ce9e4d486cf..8c696f25752 100644 --- a/mysql-test/suite/binlog_encryption/rpl_ssl.result +++ b/mysql-test/suite/binlog_encryption/rpl_ssl.result @@ -51,7 +51,7 @@ connection slave; include/stop_slave.inc CHANGE MASTER TO master_user = 'root', -master_ssl = 0, +master_ssl = 1, master_ssl_ca = '', master_ssl_cert = '', master_ssl_key = ''; diff --git a/mysql-test/suite/engines/funcs/r/rpl_000010.result b/mysql-test/suite/engines/funcs/r/rpl_000010.result index a86d71bd33f..0b3a67bfe1c 100644 --- a/mysql-test/suite/engines/funcs/r/rpl_000010.result +++ b/mysql-test/suite/engines/funcs/r/rpl_000010.result @@ -16,4 +16,5 @@ n connection master; drop table t1; connection slave; +include/wait_for_slave_to_start.inc include/rpl_end.inc diff --git a/mysql-test/suite/engines/funcs/r/rpl_dual_pos_advance.result b/mysql-test/suite/engines/funcs/r/rpl_dual_pos_advance.result index ed9060f8307..dd25cdc4d4c 100644 --- a/mysql-test/suite/engines/funcs/r/rpl_dual_pos_advance.result +++ b/mysql-test/suite/engines/funcs/r/rpl_dual_pos_advance.result @@ -3,7 +3,7 @@ include/master-slave.inc connection slave; reset master; connection master; -change master to master_host="127.0.0.1",master_port=SLAVE_PORT,master_user="root"; +change master to master_host="127.0.0.1",master_port=SLAVE_PORT,master_user="root",master_ssl_verify_server_cert=0; include/start_slave.inc connection slave; create table t1 (n int); @@ -25,4 +25,5 @@ include/stop_slave.inc reset slave; drop table t1,t4,t5,t6; connection slave; +include/wait_for_slave_to_start.inc include/rpl_end.inc diff --git a/mysql-test/suite/engines/funcs/r/rpl_flushlog_loop.result b/mysql-test/suite/engines/funcs/r/rpl_flushlog_loop.result index 527dd8dc983..56e428b3e30 100644 --- a/mysql-test/suite/engines/funcs/r/rpl_flushlog_loop.result +++ b/mysql-test/suite/engines/funcs/r/rpl_flushlog_loop.result @@ -3,11 +3,11 @@ include/master-slave.inc connection slave; include/stop_slave.inc change master to master_host='127.0.0.1',master_user='root', -master_password='',master_port=MASTER_PORT; +master_password='',master_port=MASTER_PORT, master_ssl_verify_server_cert=0; include/start_slave.inc connection master; change master to master_host='127.0.0.1',master_user='root', -master_password='',master_port=SLAVE_PORT; +master_password='',master_port=SLAVE_PORT, master_ssl_verify_server_cert=0; include/start_slave.inc flush logs; include/stop_slave.inc diff --git a/mysql-test/suite/engines/funcs/t/rpl_dual_pos_advance.test b/mysql-test/suite/engines/funcs/t/rpl_dual_pos_advance.test index bf5e84152bc..a61904edbcc 100644 --- a/mysql-test/suite/engines/funcs/t/rpl_dual_pos_advance.test +++ b/mysql-test/suite/engines/funcs/t/rpl_dual_pos_advance.test @@ -16,7 +16,7 @@ reset master; connection master; --replace_result $SLAVE_MYPORT SLAVE_PORT -eval change master to master_host="127.0.0.1",master_port=$SLAVE_MYPORT,master_user="root"; +eval change master to master_host="127.0.0.1",master_port=$SLAVE_MYPORT,master_user="root",master_ssl_verify_server_cert=0; --source include/start_slave.inc @@ -100,6 +100,7 @@ reset slave; drop table t1,t4,t5,t6; # add t2 and t3 later --sync_slave_with_master +--source include/wait_for_slave_to_start.inc # End of 4.1 tests --source include/rpl_end.inc diff --git a/mysql-test/suite/engines/funcs/t/rpl_flushlog_loop.test b/mysql-test/suite/engines/funcs/t/rpl_flushlog_loop.test index b4742246264..38da16ff169 100644 --- a/mysql-test/suite/engines/funcs/t/rpl_flushlog_loop.test +++ b/mysql-test/suite/engines/funcs/t/rpl_flushlog_loop.test @@ -11,7 +11,7 @@ connection slave; --replace_result $MASTER_MYPORT MASTER_PORT eval change master to master_host='127.0.0.1',master_user='root', - master_password='',master_port=$MASTER_MYPORT; + master_password='',master_port=$MASTER_MYPORT, master_ssl_verify_server_cert=0; --source include/start_slave.inc # # Start replication slave -> master @@ -20,7 +20,7 @@ connection master; --replace_result $SLAVE_MYPORT SLAVE_PORT eval change master to master_host='127.0.0.1',master_user='root', - master_password='',master_port=$SLAVE_MYPORT; + master_password='',master_port=$SLAVE_MYPORT, master_ssl_verify_server_cert=0; --source include/start_slave.inc # diff --git a/mysql-test/suite/galera/r/galera_query_cache_invalidate.result b/mysql-test/suite/galera/r/galera_query_cache_invalidate.result index 1c1ba1dd449..b14511134e3 100644 --- a/mysql-test/suite/galera/r/galera_query_cache_invalidate.result +++ b/mysql-test/suite/galera/r/galera_query_cache_invalidate.result @@ -7,7 +7,7 @@ call mtr.add_suppression("WSREP: Ignoring server id for non bootstrap node."); connection node_4; call mtr.add_suppression("WSREP: Ignoring server id for non bootstrap node."); connection node_3; -CHANGE MASTER TO master_host='127.0.0.1', master_user='root', master_port=NODE_MYPORT_1, master_use_gtid=current_pos;; +CHANGE MASTER TO master_host='127.0.0.1', master_user='root', master_port=NODE_MYPORT_1, master_ssl_verify_server_cert=0, master_use_gtid=current_pos; Warnings: Warning 1287 'master_use_gtid=current_pos' is deprecated and will be removed in a future release. Please use master_demote_to_slave=1 instead START SLAVE; diff --git a/mysql-test/suite/galera/t/MDEV-28053.test b/mysql-test/suite/galera/t/MDEV-28053.test index 85cb20c7e10..6a05682ba38 100644 --- a/mysql-test/suite/galera/t/MDEV-28053.test +++ b/mysql-test/suite/galera/t/MDEV-28053.test @@ -37,7 +37,7 @@ while ($counter) { --connection node_2 --disable_query_log --disable_result_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3; START SLAVE; --eval SELECT MASTER_GTID_WAIT('$gtid', 600) --enable_result_log diff --git a/mysql-test/suite/galera/t/MDEV-6860.test b/mysql-test/suite/galera/t/MDEV-6860.test index 3a8c98f317f..f92bf5953c9 100644 --- a/mysql-test/suite/galera/t/MDEV-6860.test +++ b/mysql-test/suite/galera/t/MDEV-6860.test @@ -4,7 +4,7 @@ --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3, MASTER_USE_GTID=slave_pos; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3, MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_USE_GTID=slave_pos; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_master.test b/mysql-test/suite/galera/t/galera_as_master.test index a5554a735fe..26fbd004009 100644 --- a/mysql-test/suite/galera/t/galera_as_master.test +++ b/mysql-test/suite/galera/t/galera_as_master.test @@ -9,7 +9,7 @@ --connect node_3, 127.0.0.1, root, , test, $NODE_MYPORT_3 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_1; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_1; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_master_large.test b/mysql-test/suite/galera/t/galera_as_master_large.test index fa343cd9c93..cac5b12db76 100644 --- a/mysql-test/suite/galera/t/galera_as_master_large.test +++ b/mysql-test/suite/galera/t/galera_as_master_large.test @@ -8,7 +8,7 @@ --connect node_3, 127.0.0.1, root, , test, $NODE_MYPORT_3 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_1; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_1; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_slave.test b/mysql-test/suite/galera/t/galera_as_slave.test index 859fe19c9bb..581e050bbf4 100644 --- a/mysql-test/suite/galera/t/galera_as_slave.test +++ b/mysql-test/suite/galera/t/galera_as_slave.test @@ -13,7 +13,7 @@ --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_slave_autoinc.test b/mysql-test/suite/galera/t/galera_as_slave_autoinc.test index ce4c87e2bee..733875a14be 100644 --- a/mysql-test/suite/galera/t/galera_as_slave_autoinc.test +++ b/mysql-test/suite/galera/t/galera_as_slave_autoinc.test @@ -13,7 +13,7 @@ --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_slave_gtid.inc b/mysql-test/suite/galera/t/galera_as_slave_gtid.inc index ca6cce52497..983f6ebd706 100644 --- a/mysql-test/suite/galera/t/galera_as_slave_gtid.inc +++ b/mysql-test/suite/galera/t/galera_as_slave_gtid.inc @@ -17,7 +17,7 @@ --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_slave_gtid_myisam.test b/mysql-test/suite/galera/t/galera_as_slave_gtid_myisam.test index 60476bc45a7..fd18de168f9 100644 --- a/mysql-test/suite/galera/t/galera_as_slave_gtid_myisam.test +++ b/mysql-test/suite/galera/t/galera_as_slave_gtid_myisam.test @@ -26,7 +26,7 @@ SELECT @@wsrep_on; ALTER TABLE mysql.gtid_slave_pos engine = InnoDB; --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_as_slave_nonprim.test b/mysql-test/suite/galera/t/galera_as_slave_nonprim.test index e22f0240a59..2fe608bb99e 100644 --- a/mysql-test/suite/galera/t/galera_as_slave_nonprim.test +++ b/mysql-test/suite/galera/t/galera_as_slave_nonprim.test @@ -18,7 +18,7 @@ --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=$NODE_MYPORT_4, MASTER_USER='root'; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=$NODE_MYPORT_4, MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_USER='root'; --enable_query_log START SLAVE; SET SESSION wsrep_sync_wait = 0; diff --git a/mysql-test/suite/galera/t/galera_gtid_slave.test b/mysql-test/suite/galera/t/galera_gtid_slave.test index b3fbbb02d5f..7bcaac77f81 100644 --- a/mysql-test/suite/galera/t/galera_gtid_slave.test +++ b/mysql-test/suite/galera/t/galera_gtid_slave.test @@ -16,7 +16,7 @@ --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3; --enable_query_log START SLAVE; diff --git a/mysql-test/suite/galera/t/galera_gtid_slave_sst_rsync.test b/mysql-test/suite/galera/t/galera_gtid_slave_sst_rsync.test index b2ddc7e153d..6c83c7a34cd 100644 --- a/mysql-test/suite/galera/t/galera_gtid_slave_sst_rsync.test +++ b/mysql-test/suite/galera/t/galera_gtid_slave_sst_rsync.test @@ -16,7 +16,7 @@ --echo #Connection 2 --connection node_2 --disable_query_log ---eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_PORT=$NODE_MYPORT_3,master_use_gtid=slave_pos; +--eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0, MASTER_PORT=$NODE_MYPORT_3,master_use_gtid=slave_pos; --enable_query_log START SLAVE; --sleep 1 diff --git a/mysql-test/suite/galera/t/galera_query_cache_invalidate.test b/mysql-test/suite/galera/t/galera_query_cache_invalidate.test index d72d8a9ba40..0ad9b966823 100644 --- a/mysql-test/suite/galera/t/galera_query_cache_invalidate.test +++ b/mysql-test/suite/galera/t/galera_query_cache_invalidate.test @@ -29,7 +29,7 @@ call mtr.add_suppression("WSREP: Ignoring server id for non bootstrap node."); --connection node_3 --replace_result $NODE_MYPORT_1 NODE_MYPORT_1 ---eval CHANGE MASTER TO master_host='127.0.0.1', master_user='root', master_port=$NODE_MYPORT_1, master_use_gtid=current_pos; +--eval CHANGE MASTER TO master_host='127.0.0.1', master_user='root', master_port=$NODE_MYPORT_1, master_ssl_verify_server_cert=0, master_use_gtid=current_pos START SLAVE; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/mariabackup/slave_provision_nolock.result b/mysql-test/suite/mariabackup/slave_provision_nolock.result index 445a98019b0..66e0a079a3b 100644 --- a/mysql-test/suite/mariabackup/slave_provision_nolock.result +++ b/mysql-test/suite/mariabackup/slave_provision_nolock.result @@ -28,6 +28,7 @@ CREATE TABLE t3 (file VARCHAR(255), pos INT) ENGINE=InnoDB; LOAD DATA LOCAL INFILE "BASEDIR/xtrabackup_binlog_pos_innodb" INTO TABLE t3 FIELDS ESCAPED BY '' (file, pos); CHANGE MASTER TO +master_ssl_verify_server_cert=0, master_port=PORT, master_host='127.0.0.1', master_user='root', master_log_file= "MASTER_FILE", master_log_pos= MASTER_POS; diff --git a/mysql-test/suite/mariabackup/slave_provision_nolock.test b/mysql-test/suite/mariabackup/slave_provision_nolock.test index 618f313290c..874a32d6250 100644 --- a/mysql-test/suite/mariabackup/slave_provision_nolock.test +++ b/mysql-test/suite/mariabackup/slave_provision_nolock.test @@ -139,6 +139,7 @@ eval LOAD DATA LOCAL INFILE "$basedir/xtrabackup_binlog_pos_innodb" --replace_result $SERVER_MYPORT_1 PORT $provision_master_file MASTER_FILE $provision_master_pos MASTER_POS eval CHANGE MASTER TO + master_ssl_verify_server_cert=0, master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_log_file= "$provision_master_file", master_log_pos= $provision_master_pos; diff --git a/mysql-test/suite/multi_source/gtid.result b/mysql-test/suite/multi_source/gtid.result index 6530bb744ac..8f792f98edb 100644 --- a/mysql-test/suite/multi_source/gtid.result +++ b/mysql-test/suite/multi_source/gtid.result @@ -3,8 +3,8 @@ connect slave2,127.0.0.1,root,,,$SERVER_MYPORT_4; connect master1,127.0.0.1,root,,,$SERVER_MYPORT_1; connect master2,127.0.0.1,root,,,$SERVER_MYPORT_2; connection slave1; -CHANGE MASTER 'slave1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root'; -CHANGE MASTER 'slave2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root'; +CHANGE MASTER 'slave1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; +CHANGE MASTER 'slave2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; set default_master_connection = 'slave1'; START SLAVE; include/wait_for_slave_to_start.inc @@ -13,7 +13,7 @@ START SLAVE; include/wait_for_slave_to_start.inc set default_master_connection = ''; connection slave2; -CHANGE MASTER TO master_port=MYPORT_3, master_host='127.0.0.1', master_user='root'; +CHANGE MASTER TO master_port=MYPORT_3, master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; start all slaves; Warnings: Note 1937 SLAVE '' started @@ -47,8 +47,8 @@ connection master2; INSERT INTO t2 VALUES (2, "switch1"); INSERT INTO t3 VALUES (202, "switch1 b"); connection slave2; -CHANGE MASTER 'slave1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root'; -CHANGE MASTER 'slave2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root'; +CHANGE MASTER 'slave1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; +CHANGE MASTER 'slave2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; SET default_master_connection = 'slave1'; START SLAVE; include/wait_for_slave_to_start.inc @@ -75,7 +75,7 @@ INSERT INTO t3 VALUES (204, "switch 3 b"); connection slave2; include/sync_with_master_gtid.inc connection slave1; -CHANGE MASTER TO master_port=MYPORT_4, master_host='127.0.0.1', master_user='root'; +CHANGE MASTER TO master_port=MYPORT_4, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; START SLAVE; SELECT * FROM t1 ORDER BY a; a b diff --git a/mysql-test/suite/multi_source/gtid.test b/mysql-test/suite/multi_source/gtid.test index 9fc7a66893c..2d6d1280c58 100644 --- a/mysql-test/suite/multi_source/gtid.test +++ b/mysql-test/suite/multi_source/gtid.test @@ -12,9 +12,9 @@ --connection slave1 --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'slave1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER 'slave1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'slave2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER 'slave2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; set default_master_connection = 'slave1'; START SLAVE; --source include/wait_for_slave_to_start.inc @@ -25,7 +25,7 @@ set default_master_connection = ''; --connection slave2 --replace_result $SERVER_MYPORT_3 MYPORT_3 -eval CHANGE MASTER TO master_port=$SERVER_MYPORT_3, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER TO master_port=$SERVER_MYPORT_3, master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; start all slaves; --source include/wait_for_slave_to_start.inc @@ -73,9 +73,9 @@ INSERT INTO t3 VALUES (202, "switch1 b"); --connection slave2 --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'slave1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER 'slave1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'slave2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER 'slave2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; SET default_master_connection = 'slave1'; START SLAVE; --source include/wait_for_slave_to_start.inc @@ -125,7 +125,7 @@ INSERT INTO t3 VALUES (204, "switch 3 b"); --connection slave1 --replace_result $SERVER_MYPORT_4 MYPORT_4 -eval CHANGE MASTER TO master_port=$SERVER_MYPORT_4, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER TO master_port=$SERVER_MYPORT_4, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; START SLAVE; --let $wait_condition= SELECT (SELECT COUNT(*) FROM t1)=3 AND (SELECT COUNT(*) FROM t2)=4 AND (SELECT COUNT(*) FROM t3)=7 --source include/wait_condition.inc diff --git a/mysql-test/suite/multi_source/gtid_ignore_duplicates.result b/mysql-test/suite/multi_source/gtid_ignore_duplicates.result index e142ff8b981..d23e7597543 100644 --- a/mysql-test/suite/multi_source/gtid_ignore_duplicates.result +++ b/mysql-test/suite/multi_source/gtid_ignore_duplicates.result @@ -10,8 +10,8 @@ SET @old_ignore_duplicates= @@GLOBAL.gtid_ignore_duplicates; SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 1; SET SESSION gtid_domain_id= 1; -CHANGE MASTER 'b2a' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; -CHANGE MASTER 'c2a' TO master_port=MYPORT_3, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +CHANGE MASTER 'b2a' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; +CHANGE MASTER 'c2a' TO master_port=MYPORT_3, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'b2a'; START SLAVE; include/wait_for_slave_to_start.inc @@ -26,8 +26,8 @@ SET @old_ignore_duplicates= @@GLOBAL.gtid_ignore_duplicates; SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 2; SET SESSION gtid_domain_id= 2; -CHANGE MASTER 'a2b' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; -CHANGE MASTER 'c2b' TO master_port=MYPORT_3, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +CHANGE MASTER 'a2b' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; +CHANGE MASTER 'c2b' TO master_port=MYPORT_3, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'a2b'; START SLAVE; include/wait_for_slave_to_start.inc @@ -42,8 +42,8 @@ SET @old_ignore_duplicates= @@GLOBAL.gtid_ignore_duplicates; SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 3; SET SESSION gtid_domain_id= 3; -CHANGE MASTER 'a2c' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; -CHANGE MASTER 'b2c' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +CHANGE MASTER 'a2c' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; +CHANGE MASTER 'b2c' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'a2c'; START SLAVE; include/wait_for_slave_to_start.inc @@ -58,7 +58,7 @@ SET @old_ignore_duplicates= @@GLOBAL.gtid_ignore_duplicates; SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 1; SET SESSION gtid_domain_id= 1; -CHANGE MASTER 'a2d' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +CHANGE MASTER 'a2d' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'a2d'; START SLAVE; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/gtid_ignore_duplicates.test b/mysql-test/suite/multi_source/gtid_ignore_duplicates.test index 3d2d151bd0d..2e5bd6da482 100644 --- a/mysql-test/suite/multi_source/gtid_ignore_duplicates.test +++ b/mysql-test/suite/multi_source/gtid_ignore_duplicates.test @@ -20,9 +20,9 @@ SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 1; SET SESSION gtid_domain_id= 1; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'b2a' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'b2a' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --replace_result $SERVER_MYPORT_3 MYPORT_3 -eval CHANGE MASTER 'c2a' TO master_port=$SERVER_MYPORT_3, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'c2a' TO master_port=$SERVER_MYPORT_3, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'b2a'; START SLAVE; --source include/wait_for_slave_to_start.inc @@ -39,9 +39,9 @@ SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 2; SET SESSION gtid_domain_id= 2; --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'a2b' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'a2b' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --replace_result $SERVER_MYPORT_3 MYPORT_3 -eval CHANGE MASTER 'c2b' TO master_port=$SERVER_MYPORT_3, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'c2b' TO master_port=$SERVER_MYPORT_3, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'a2b'; START SLAVE; --source include/wait_for_slave_to_start.inc @@ -58,9 +58,9 @@ SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 3; SET SESSION gtid_domain_id= 3; --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'a2c' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'a2c' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'b2c' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'b2c' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'a2c'; START SLAVE; --source include/wait_for_slave_to_start.inc @@ -77,7 +77,7 @@ SET GLOBAL gtid_ignore_duplicates=1; SET GLOBAL gtid_domain_id= 1; SET SESSION gtid_domain_id= 1; --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'a2d' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'a2d' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'a2d'; START SLAVE; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/gtid_slave_pos.result b/mysql-test/suite/multi_source/gtid_slave_pos.result index 44eb482327d..00c9404fe3f 100644 --- a/mysql-test/suite/multi_source/gtid_slave_pos.result +++ b/mysql-test/suite/multi_source/gtid_slave_pos.result @@ -2,8 +2,8 @@ connect slave1,127.0.0.1,root,,,$SERVER_MYPORT_3; connect master1,127.0.0.1,root,,,$SERVER_MYPORT_1; connect master2,127.0.0.1,root,,,$SERVER_MYPORT_2; connection slave1; -CHANGE MASTER 'slave1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; -CHANGE MASTER 'slave2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +CHANGE MASTER 'slave1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; +CHANGE MASTER 'slave2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'slave1'; START SLAVE; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/gtid_slave_pos.test b/mysql-test/suite/multi_source/gtid_slave_pos.test index cc418d76870..d5356ca6302 100644 --- a/mysql-test/suite/multi_source/gtid_slave_pos.test +++ b/mysql-test/suite/multi_source/gtid_slave_pos.test @@ -11,9 +11,9 @@ --connection slave1 --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'slave1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'slave1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'slave2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval CHANGE MASTER 'slave2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; set default_master_connection = 'slave1'; START SLAVE; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/info_logs.result b/mysql-test/suite/multi_source/info_logs.result index a35a20bdbf7..dd06fd0aeb9 100644 --- a/mysql-test/suite/multi_source/info_logs.result +++ b/mysql-test/suite/multi_source/info_logs.result @@ -10,7 +10,7 @@ multi-master.info change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave 'master1'; set default_master_connection = 'master1'; @@ -29,7 +29,7 @@ master1 change master 'MASTER 2.2' to master_port=MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave 'MASTER 2.2'; set default_master_connection = 'MASTER 2.2'; @@ -73,7 +73,7 @@ set default_master_connection = ''; change master to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; include/wait_for_slave_to_start.inc @@ -95,16 +95,16 @@ MASTER 2.2 # show all slaves status; Connection_name Slave_SQL_State Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Rewrite_DB Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id Master_SSL_Crl Master_SSL_Crlpath Using_Gtid Gtid_IO_Pos Replicate_Do_Domain_Ids Replicate_Ignore_Domain_Ids Parallel_Mode SQL_Delay SQL_Remaining_Delay Slave_SQL_Running_State Slave_DDL_Groups Slave_Non_Transactional_Groups Slave_Transactional_Groups Retried_transactions Max_relay_log_size Executed_log_entries Slave_received_heartbeats Slave_heartbeat_period Gtid_Slave_Pos - Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_1 60 master-bin.000001 relay.000002 master-bin.000001 Yes Yes 0 0 None 0 No 0 No 0 0 1 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 7 0 60.000 -MASTER 2.2 Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_2 60 master-bin.000001 relay-master@00202@002e2.000002 master-bin.000001 Yes Yes 0 0 None 0 No 0 No 0 0 2 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 7 0 60.000 + Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_1 60 master-bin.000001 relay.000002 master-bin.000001 Yes Yes 0 0 None 0 Yes 0 No 0 0 1 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 7 0 60.000 +MASTER 2.2 Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_2 60 master-bin.000001 relay-master@00202@002e2.000002 master-bin.000001 Yes Yes 0 0 None 0 Yes 0 No 0 0 2 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 7 0 60.000 include/wait_for_slave_to_start.inc set default_master_connection = 'MASTER 2.2'; include/wait_for_slave_to_start.inc set default_master_connection = ''; show all slaves status; Connection_name Slave_SQL_State Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Rewrite_DB Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id Master_SSL_Crl Master_SSL_Crlpath Using_Gtid Gtid_IO_Pos Replicate_Do_Domain_Ids Replicate_Ignore_Domain_Ids Parallel_Mode SQL_Delay SQL_Remaining_Delay Slave_SQL_Running_State Slave_DDL_Groups Slave_Non_Transactional_Groups Slave_Transactional_Groups Retried_transactions Max_relay_log_size Executed_log_entries Slave_received_heartbeats Slave_heartbeat_period Gtid_Slave_Pos - Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_1 60 master-bin.000001 relay.000004 master-bin.000001 Yes Yes 0 0 None 0 No 0 No 0 0 1 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 6 0 60.000 -MASTER 2.2 Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_2 60 master-bin.000001 relay-master@00202@002e2.000004 master-bin.000001 Yes Yes 0 0 None 0 No 0 No 0 0 2 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 6 0 60.000 + Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_1 60 master-bin.000001 relay.000004 master-bin.000001 Yes Yes 0 0 None 0 Yes 0 No 0 0 1 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 6 0 60.000 +MASTER 2.2 Slave has read all relay log; waiting for more updates Waiting for master to send event 127.0.0.1 root MYPORT_2 60 master-bin.000001 relay-master@00202@002e2.000004 master-bin.000001 Yes Yes 0 0 None 0 Yes 0 No 0 0 2 No optimistic 0 NULL Slave has read all relay log; waiting for more updates 0 0 0 0 1073741824 6 0 60.000 # # List of files matching '*info*' pattern # after slave server restart diff --git a/mysql-test/suite/multi_source/info_logs.test b/mysql-test/suite/multi_source/info_logs.test index f8352978645..5511a04a81e 100644 --- a/mysql-test/suite/multi_source/info_logs.test +++ b/mysql-test/suite/multi_source/info_logs.test @@ -30,7 +30,7 @@ eval change master 'master1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave 'master1'; @@ -55,7 +55,7 @@ set default_master_connection = 'master1'; eval change master 'MASTER 2.2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave 'MASTER 2.2'; @@ -109,7 +109,7 @@ set default_master_connection = ''; eval change master to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; diff --git a/mysql-test/suite/multi_source/load_data.result b/mysql-test/suite/multi_source/load_data.result index 21b1bfff488..a3d77414e8c 100644 --- a/mysql-test/suite/multi_source/load_data.result +++ b/mysql-test/suite/multi_source/load_data.result @@ -2,8 +2,8 @@ connect slave,127.0.0.1,root,,,$SERVER_MYPORT_3; connect master1,127.0.0.1,root,,,$SERVER_MYPORT_1; connect master2,127.0.0.1,root,,,$SERVER_MYPORT_2; connection slave; -change master '' to master_port=MYPORT_1, master_host='127.0.0.1', master_user='root'; -change master 'master2' to master_port=MYPORT_2, master_host='127.0.0.1', master_user='root'; +change master '' to master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; +change master 'master2' to master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; start all slaves; Warnings: Note 1937 SLAVE 'master2' started diff --git a/mysql-test/suite/multi_source/load_data.test b/mysql-test/suite/multi_source/load_data.test index 94b328d56ae..8927b818b3f 100644 --- a/mysql-test/suite/multi_source/load_data.test +++ b/mysql-test/suite/multi_source/load_data.test @@ -11,9 +11,9 @@ --connection slave --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master '' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root'; +eval change master '' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'master2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root'; +eval change master 'master2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; start all slaves; set default_master_connection = ''; diff --git a/mysql-test/suite/multi_source/mdev-8874.result b/mysql-test/suite/multi_source/mdev-8874.result index 12bc251f4e2..4ab3feeaacf 100644 --- a/mysql-test/suite/multi_source/mdev-8874.result +++ b/mysql-test/suite/multi_source/mdev-8874.result @@ -24,9 +24,9 @@ insert into t1 values(1); create table t2(a int); insert into t2 values(1); connection server_4; -change master 'm1' to master_port=MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; -change master 'm2' to master_port=MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; -change master to master_port=MYPORT_3 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +change master 'm1' to master_port=MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; +change master 'm2' to master_port=MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; +change master to master_port=MYPORT_3 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start all slaves; set default_master_connection = 'm1'; include/wait_for_slave_to_start.inc @@ -76,9 +76,9 @@ Note 4190 RESET SLAVE is implicitly changing the value of 'Using_Gtid' from 'No' drop database a; drop database b; drop database c; -change master 'm1' to master_port=MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; -change master 'm2' to master_port=MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; -change master to master_port=MYPORT_3 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +change master 'm1' to master_port=MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; +change master 'm2' to master_port=MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; +change master to master_port=MYPORT_3 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start all slaves; Warnings: Note 1937 SLAVE 'm2' started diff --git a/mysql-test/suite/multi_source/mdev-8874.test b/mysql-test/suite/multi_source/mdev-8874.test index 1a99ae73d9b..b581af912ce 100644 --- a/mysql-test/suite/multi_source/mdev-8874.test +++ b/mysql-test/suite/multi_source/mdev-8874.test @@ -40,11 +40,11 @@ insert into t2 values(1); --connection server_4 --disable_warnings --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; --replace_result $SERVER_MYPORT_3 MYPORT_3 -eval change master to master_port=$SERVER_MYPORT_3 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master to master_port=$SERVER_MYPORT_3 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start all slaves; set default_master_connection = 'm1'; --source include/wait_for_slave_to_start.inc @@ -78,11 +78,11 @@ drop database a; drop database b; drop database c; --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; --replace_result $SERVER_MYPORT_3 MYPORT_3 -eval change master to master_port=$SERVER_MYPORT_3 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master to master_port=$SERVER_MYPORT_3 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start all slaves; set default_master_connection = 'm1'; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/mdev-9544.result b/mysql-test/suite/multi_source/mdev-9544.result index 452964fd862..4468d9c14a8 100644 --- a/mysql-test/suite/multi_source/mdev-9544.result +++ b/mysql-test/suite/multi_source/mdev-9544.result @@ -24,9 +24,9 @@ insert into t1 values(1); create table t2(a int); insert into t2 values(1); connection server_4; -change master 'm1' to master_port=MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; -change master 'm2' to master_port=MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; -change master to master_port=MYPORT_3 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +change master 'm1' to master_port=MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; +change master 'm2' to master_port=MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; +change master to master_port=MYPORT_3 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start all slaves; set default_master_connection = 'm1'; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/mdev-9544.test b/mysql-test/suite/multi_source/mdev-9544.test index fd89bdfa744..56bdfd96eb4 100644 --- a/mysql-test/suite/multi_source/mdev-9544.test +++ b/mysql-test/suite/multi_source/mdev-9544.test @@ -37,11 +37,11 @@ insert into t2 values(1); --connection server_4 --disable_warnings --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; --replace_result $SERVER_MYPORT_3 MYPORT_3 -eval change master to master_port=$SERVER_MYPORT_3 , master_host='127.0.0.1', master_user='root', master_use_gtid=no; +eval change master to master_port=$SERVER_MYPORT_3 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start all slaves; set default_master_connection = 'm1'; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/multi_parallel.result b/mysql-test/suite/multi_source/multi_parallel.result index bca01d57932..9553a627b00 100644 --- a/mysql-test/suite/multi_source/multi_parallel.result +++ b/mysql-test/suite/multi_source/multi_parallel.result @@ -5,11 +5,11 @@ set global slave_parallel_threads=10; change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', master_ssl_verify_server_cert=0; change master 'master2' to master_port=MYPORT_2, master_host='127.0.0.1', -master_user='root'; +master_user='root', master_ssl_verify_server_cert=0; start all slaves; set default_master_connection = 'master1'; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/multi_parallel.test b/mysql-test/suite/multi_source/multi_parallel.test index 2bbb344378c..586e9106e47 100644 --- a/mysql-test/suite/multi_source/multi_parallel.test +++ b/mysql-test/suite/multi_source/multi_parallel.test @@ -18,13 +18,13 @@ set global slave_parallel_threads=10; eval change master 'master1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', master_ssl_verify_server_cert=0; --replace_result $SERVER_MYPORT_2 MYPORT_2 eval change master 'master2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', -master_user='root'; +master_user='root', master_ssl_verify_server_cert=0; #start all slaves diff --git a/mysql-test/suite/multi_source/multi_source_slave_alias_replica.result b/mysql-test/suite/multi_source/multi_source_slave_alias_replica.result index 355919def5a..f81bc73ec80 100644 --- a/mysql-test/suite/multi_source/multi_source_slave_alias_replica.result +++ b/mysql-test/suite/multi_source/multi_source_slave_alias_replica.result @@ -2,8 +2,8 @@ connect slave,127.0.0.1,root,,,$SERVER_MYPORT_3; connect master1,127.0.0.1,root,,,$SERVER_MYPORT_1; connect master2,127.0.0.1,root,,,$SERVER_MYPORT_2; connection slave; -CHANGE MASTER 'slave1' TO MASTER_PORT=MYPORT_1, MASTER_HOST='127.0.0.1', MASTER_USER='root'; -CHANGE MASTER 'slave2' TO MASTER_PORT=MYPORT_2, MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER 'slave1' TO MASTER_PORT=MYPORT_1, MASTER_HOST='127.0.0.1', MASTER_USER='root', master_ssl_verify_server_cert=0; +CHANGE MASTER 'slave2' TO MASTER_PORT=MYPORT_2, MASTER_HOST='127.0.0.1', MASTER_USER='root', master_ssl_verify_server_cert=0; START REPLICA 'slave1'; SET default_master_connection = 'slave1'; include/wait_for_slave_to_start.inc @@ -49,7 +49,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -111,7 +111,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert diff --git a/mysql-test/suite/multi_source/multi_source_slave_alias_replica.test b/mysql-test/suite/multi_source/multi_source_slave_alias_replica.test index 409718dd4e7..0e93d989ed0 100644 --- a/mysql-test/suite/multi_source/multi_source_slave_alias_replica.test +++ b/mysql-test/suite/multi_source/multi_source_slave_alias_replica.test @@ -26,9 +26,9 @@ --connection slave --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'slave1' TO MASTER_PORT=$SERVER_MYPORT_1, MASTER_HOST='127.0.0.1', MASTER_USER='root'; +eval CHANGE MASTER 'slave1' TO MASTER_PORT=$SERVER_MYPORT_1, MASTER_HOST='127.0.0.1', MASTER_USER='root', master_ssl_verify_server_cert=0; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'slave2' TO MASTER_PORT=$SERVER_MYPORT_2, MASTER_HOST='127.0.0.1', MASTER_USER='root'; +eval CHANGE MASTER 'slave2' TO MASTER_PORT=$SERVER_MYPORT_2, MASTER_HOST='127.0.0.1', MASTER_USER='root', master_ssl_verify_server_cert=0; START REPLICA 'slave1'; SET default_master_connection = 'slave1'; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/multisource.result b/mysql-test/suite/multi_source/multisource.result index 4b53b4653cd..ca420f9a9b6 100644 --- a/mysql-test/suite/multi_source/multisource.result +++ b/mysql-test/suite/multi_source/multisource.result @@ -6,7 +6,8 @@ ERROR HY000: Incorrect arguments to MASTER_HOST change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', +master_ssl_verify_server_cert=0; start slave 'master1'; set default_master_connection = 'master1'; include/wait_for_slave_to_start.inc @@ -100,6 +101,7 @@ change master to master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', +master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/multisource_for_channel.result b/mysql-test/suite/multi_source/multisource_for_channel.result index 8176bd545ee..1f790d52353 100644 --- a/mysql-test/suite/multi_source/multisource_for_channel.result +++ b/mysql-test/suite/multi_source/multisource_for_channel.result @@ -7,7 +7,7 @@ ERROR HY000: Incorrect arguments to MASTER_HOST change master to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no for channel 'master1'; start slave for channel 'master1'; @@ -103,7 +103,7 @@ set default_master_connection = ''; change master to master_port=MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/multisource_for_channel.test b/mysql-test/suite/multi_source/multisource_for_channel.test index b3feb4b9da6..0538abb5114 100644 --- a/mysql-test/suite/multi_source/multisource_for_channel.test +++ b/mysql-test/suite/multi_source/multisource_for_channel.test @@ -29,7 +29,7 @@ change master to master_host='' for channel 'abc2'; eval change master to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no for channel 'master1'; @@ -155,7 +155,7 @@ set default_master_connection = ''; eval change master to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; diff --git a/mysql-test/suite/multi_source/relaylog_events.result b/mysql-test/suite/multi_source/relaylog_events.result index 5a4f480b32b..30c857275fd 100644 --- a/mysql-test/suite/multi_source/relaylog_events.result +++ b/mysql-test/suite/multi_source/relaylog_events.result @@ -2,7 +2,7 @@ connect slave,127.0.0.1,root,,,$SERVER_MYPORT_3; change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', master_ssl_verify_server_cert=0; start slave 'master1'; set default_master_connection = 'master1'; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/relaylog_events.test b/mysql-test/suite/multi_source/relaylog_events.test index 7e5257af837..a88f825858d 100644 --- a/mysql-test/suite/multi_source/relaylog_events.test +++ b/mysql-test/suite/multi_source/relaylog_events.test @@ -12,7 +12,7 @@ eval change master 'master1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', master_ssl_verify_server_cert=0; start slave 'master1'; set default_master_connection = 'master1'; diff --git a/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.result b/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.result index 3be8b364593..6af9801db64 100644 --- a/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.result +++ b/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.result @@ -3,8 +3,8 @@ connect server_2,127.0.0.1,root,,,$SERVER_MYPORT_2; connect server_3,127.0.0.1,root,,,$SERVER_MYPORT_3; # Connect the slave (server_3) to two masters (server_1 and server_2) connection server_3; -CHANGE MASTER 'm1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root'; -CHANGE MASTER 'm2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root'; +CHANGE MASTER 'm1' TO master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; +CHANGE MASTER 'm2' TO master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; # Apply events from server_1 (m1) into m1_test create database m1_test; SET @@global.'m1'.replicate_rewrite_db='test->m1_test'; diff --git a/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.test b/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.test index e1bbfabe180..b7ee88611be 100644 --- a/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.test +++ b/mysql-test/suite/multi_source/replicate_rewrite_db_dynamic.test @@ -22,9 +22,9 @@ --echo # Connect the slave (server_3) to two masters (server_1 and server_2) --connection server_3 --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'm1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER 'm1' TO master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'm2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root'; +eval CHANGE MASTER 'm2' TO master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; --echo # Apply events from server_1 (m1) into m1_test create database m1_test; diff --git a/mysql-test/suite/multi_source/reset_slave.result b/mysql-test/suite/multi_source/reset_slave.result index 2e9ce5e896f..387efc2369b 100644 --- a/mysql-test/suite/multi_source/reset_slave.result +++ b/mysql-test/suite/multi_source/reset_slave.result @@ -1,7 +1,7 @@ connect slave,127.0.0.1,root,,,$SERVER_MYPORT_3; change master 'master1' to master_port=MYPORT_1, -master_host='127.0.0.1', +master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; start slave 'master1'; set default_master_connection = 'master1'; @@ -14,14 +14,14 @@ connection slave; stop slave 'master1'; show slave 'master1' status; Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Rewrite_DB Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id Master_SSL_Crl Master_SSL_Crlpath Using_Gtid Gtid_IO_Pos Replicate_Do_Domain_Ids Replicate_Ignore_Domain_Ids Parallel_Mode SQL_Delay SQL_Remaining_Delay Slave_SQL_Running_State Slave_DDL_Groups Slave_Non_Transactional_Groups Slave_Transactional_Groups - 127.0.0.1 root MYPORT_1 60 master-bin.000001 mysqld-relay-bin-master1.000002 master-bin.000001 No No 0 0 None 0 No NULL No 0 0 1 Slave_Pos 0-1-3 optimistic 0 NULL 2 1 0 + 127.0.0.1 root MYPORT_1 60 master-bin.000001 mysqld-relay-bin-master1.000002 master-bin.000001 No No 0 0 None 0 Yes NULL No 0 0 1 Slave_Pos 0-1-3 optimistic 0 NULL 2 1 0 mysqld-relay-bin-master1.000001 mysqld-relay-bin-master1.000002 mysqld-relay-bin-master1.index reset slave 'master1'; show slave 'master1' status; Slave_IO_State Master_Host Master_User Master_Port Connect_Retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_Rewrite_DB Replicate_Do_DB Replicate_Ignore_DB Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table Last_Errno Last_Error Skip_Counter Exec_Master_Log_Pos Relay_Log_Space Until_Condition Until_Log_File Until_Log_Pos Master_SSL_Allowed Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert Master_SSL_Cipher Master_SSL_Key Seconds_Behind_Master Master_SSL_Verify_Server_Cert Last_IO_Errno Last_IO_Error Last_SQL_Errno Last_SQL_Error Replicate_Ignore_Server_Ids Master_Server_Id Master_SSL_Crl Master_SSL_Crlpath Using_Gtid Gtid_IO_Pos Replicate_Do_Domain_Ids Replicate_Ignore_Domain_Ids Parallel_Mode SQL_Delay SQL_Remaining_Delay Slave_SQL_Running_State Slave_DDL_Groups Slave_Non_Transactional_Groups Slave_Transactional_Groups - 127.0.0.1 root MYPORT_1 60 4 No No 0 0 0 None 0 No NULL No 0 0 1 Slave_Pos optimistic 0 NULL 2 1 0 + 127.0.0.1 root MYPORT_1 60 4 No No 0 0 0 None 0 Yes NULL No 0 0 1 Slave_Pos optimistic 0 NULL 2 1 0 reset slave 'master1' all; show slave 'master1' status; ERROR HY000: There is no master connection 'master1' diff --git a/mysql-test/suite/multi_source/reset_slave.test b/mysql-test/suite/multi_source/reset_slave.test index bfdf382030a..f3d71226093 100644 --- a/mysql-test/suite/multi_source/reset_slave.test +++ b/mysql-test/suite/multi_source/reset_slave.test @@ -11,7 +11,7 @@ --replace_result $SERVER_MYPORT_1 MYPORT_1 eval change master 'master1' to master_port=$SERVER_MYPORT_1, -master_host='127.0.0.1', +master_host='127.0.0.1', master_ssl_verify_server_cert=0, master_user='root'; start slave 'master1'; diff --git a/mysql-test/suite/multi_source/simple.result b/mysql-test/suite/multi_source/simple.result index 65c25b88e44..4e70e7c9548 100644 --- a/mysql-test/suite/multi_source/simple.result +++ b/mysql-test/suite/multi_source/simple.result @@ -2,8 +2,8 @@ connect slave,127.0.0.1,root,,,$SERVER_MYPORT_3; connect master1,127.0.0.1,root,,,$SERVER_MYPORT_1; connect master2,127.0.0.1,root,,,$SERVER_MYPORT_2; connection slave; -change master 'slave1' to master_port=MYPORT_1, master_host='127.0.0.1', master_user='root'; -change master 'slave2' to master_port=MYPORT_2, master_host='127.0.0.1', master_user='root'; +change master 'slave1' to master_port=MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; +change master 'slave2' to master_port=MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; start slave 'slave1'; set default_master_connection = 'slave1'; include/wait_for_slave_to_start.inc @@ -47,7 +47,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -109,7 +109,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -151,7 +151,7 @@ HOST 127.0.0.1 PORT # USER root USING_GTID SLAVE_POS -SSL_ALLOWED NO +SSL_ALLOWED YES SSL_CA_FILE SSL_CA_PATH SSL_CERTIFICATE @@ -171,7 +171,7 @@ HOST 127.0.0.1 PORT # USER root USING_GTID SLAVE_POS -SSL_ALLOWED NO +SSL_ALLOWED YES SSL_CA_FILE SSL_CA_PATH SSL_CERTIFICATE @@ -236,7 +236,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -294,7 +294,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -356,7 +356,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -420,7 +420,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert @@ -486,7 +486,7 @@ Relay_Log_Space Until_Condition None Until_Log_File Until_Log_Pos 0 -Master_SSL_Allowed No +Master_SSL_Allowed Yes Master_SSL_CA_File Master_SSL_CA_Path Master_SSL_Cert diff --git a/mysql-test/suite/multi_source/simple.test b/mysql-test/suite/multi_source/simple.test index 070d4745066..ac5e84586ae 100644 --- a/mysql-test/suite/multi_source/simple.test +++ b/mysql-test/suite/multi_source/simple.test @@ -13,9 +13,9 @@ --connection slave --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master 'slave1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root'; +eval change master 'slave1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'slave2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root'; +eval change master 'slave2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; start slave 'slave1'; set default_master_connection = 'slave1'; --source include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/skip_counter.result b/mysql-test/suite/multi_source/skip_counter.result index 4573d54ca38..6473ee63b86 100644 --- a/mysql-test/suite/multi_source/skip_counter.result +++ b/mysql-test/suite/multi_source/skip_counter.result @@ -12,7 +12,7 @@ connect slave,127.0.0.1,root,,,$SERVER_MYPORT_3; change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave 'master1'; set default_master_connection = 'master1'; @@ -21,7 +21,7 @@ set default_master_connection = 'master2'; change master 'master2' to master_port=MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; set global sql_slave_skip_counter = 2; select @@global.sql_slave_skip_counter; diff --git a/mysql-test/suite/multi_source/skip_counter.test b/mysql-test/suite/multi_source/skip_counter.test index e89480f55c5..04aaf6576d4 100644 --- a/mysql-test/suite/multi_source/skip_counter.test +++ b/mysql-test/suite/multi_source/skip_counter.test @@ -38,7 +38,7 @@ create table db.t3 (i int) engine=MyISAM; eval change master 'master1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; start slave 'master1'; @@ -54,7 +54,7 @@ set default_master_connection = 'master2'; eval change master 'master2' to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=no; # the schema creation will be replicated from the 1st master, diff --git a/mysql-test/suite/multi_source/status_vars.result b/mysql-test/suite/multi_source/status_vars.result index 35a58e0fef1..7e91829ab24 100644 --- a/mysql-test/suite/multi_source/status_vars.result +++ b/mysql-test/suite/multi_source/status_vars.result @@ -3,7 +3,7 @@ call mtr.add_suppression("Connection 'master1' already exists"); change master 'master1' to master_port=MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_heartbeat_period = 25; start slave 'master1'; set default_master_connection = 'master1'; @@ -12,7 +12,7 @@ set default_master_connection = ''; change master to master_port=MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_heartbeat_period=35; start slave; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/multi_source/status_vars.test b/mysql-test/suite/multi_source/status_vars.test index e76a403db33..eecf129e679 100644 --- a/mysql-test/suite/multi_source/status_vars.test +++ b/mysql-test/suite/multi_source/status_vars.test @@ -15,7 +15,7 @@ call mtr.add_suppression("Connection 'master1' already exists"); eval change master 'master1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_heartbeat_period = 25; start slave 'master1'; @@ -31,7 +31,7 @@ set default_master_connection = ''; eval change master to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', -master_user='root', +master_user='root', master_ssl_verify_server_cert=0, master_heartbeat_period=35; start slave; diff --git a/mysql-test/suite/rpl/include/multisource.inc b/mysql-test/suite/rpl/include/multisource.inc index 96c4a9aa348..8d9fa1f4de5 100644 --- a/mysql-test/suite/rpl/include/multisource.inc +++ b/mysql-test/suite/rpl/include/multisource.inc @@ -38,7 +38,8 @@ change master 'abc2' to master_host=''; eval change master 'master1' to master_port=$SERVER_MYPORT_1, master_host='127.0.0.1', -master_user='root'; +master_user='root', +master_ssl_verify_server_cert=0; start slave 'master1'; set default_master_connection = 'master1'; @@ -160,6 +161,7 @@ eval change master to master_port=$SERVER_MYPORT_2, master_host='127.0.0.1', master_user='root', +master_ssl_verify_server_cert=0, master_use_gtid=no; start slave; diff --git a/mysql-test/suite/rpl/include/rpl_change_master_demote.inc b/mysql-test/suite/rpl/include/rpl_change_master_demote.inc index 4c563454a5b..8ecdf0764bf 100644 --- a/mysql-test/suite/rpl/include/rpl_change_master_demote.inc +++ b/mysql-test/suite/rpl/include/rpl_change_master_demote.inc @@ -29,7 +29,7 @@ if (`SELECT strcmp("$ignore_domain_ids","") != 0`) --echo # gtid_current_pos calculation --let $current_pos= `SELECT @@gtid_current_pos` --replace_result $SLAVE_MYPORT SLAVE_PORT ---eval CHANGE MASTER TO master_host='127.0.0.1', master_port=$SLAVE_MYPORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 $extra_cm_args +--eval CHANGE MASTER TO master_host='127.0.0.1', master_port=$SLAVE_MYPORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 $extra_cm_args SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; --let $slave_pos= `SELECT @@gtid_slave_pos` --echo # Validating gtid_slave_pos == gtid_binlog_pos.. diff --git a/mysql-test/suite/rpl/r/grant_replication_slave.result b/mysql-test/suite/rpl/r/grant_replication_slave.result index 6ded7e72327..b8de7e9fff2 100644 --- a/mysql-test/suite/rpl/r/grant_replication_slave.result +++ b/mysql-test/suite/rpl/r/grant_replication_slave.result @@ -38,6 +38,6 @@ drop database mysqltest1; connection slave; stop slave; change master to master_user='root'; -start slave; +include/start_slave.inc include/rpl_end.inc drop user rpl@localhost; diff --git a/mysql-test/suite/rpl/r/rpl_000010.result b/mysql-test/suite/rpl/r/rpl_000010.result index a86d71bd33f..0b3a67bfe1c 100644 --- a/mysql-test/suite/rpl/r/rpl_000010.result +++ b/mysql-test/suite/rpl/r/rpl_000010.result @@ -16,4 +16,5 @@ n connection master; drop table t1; connection slave; +include/wait_for_slave_to_start.inc include/rpl_end.inc diff --git a/mysql-test/suite/rpl/r/rpl_change_master_demote.result b/mysql-test/suite/rpl/r/rpl_change_master_demote.result index 38cff83829e..778fa7c1487 100644 --- a/mysql-test/suite/rpl/r/rpl_change_master_demote.result +++ b/mysql-test/suite/rpl/r/rpl_change_master_demote.result @@ -24,7 +24,7 @@ GTID_CURRENT_POS GTID_SLAVE_POS # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 ; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 ; SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS @@ -90,7 +90,7 @@ GTID_CURRENT_POS 0-1-2 GTID_SLAVE_POS # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 ; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 ; SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-2 @@ -149,7 +149,7 @@ GTID_CURRENT_POS 0-1-6 GTID_SLAVE_POS 0-2-5 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 ; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 ; SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-6 @@ -210,7 +210,7 @@ GTID_CURRENT_POS 0-1-10 GTID_SLAVE_POS 0-1-10 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 ; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 ; SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-10 @@ -274,7 +274,7 @@ GTID_CURRENT_POS 0-1-14,1-1-2 GTID_SLAVE_POS 0-2-13 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 ; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 ; SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-14,1-1-2 @@ -356,7 +356,7 @@ GTID_CURRENT_POS 0-1-18,1-1-2,2-1-2 GTID_SLAVE_POS 0-1-18,1-1-2 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 ; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 ; SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-18,1-3-4,2-1-2,4-3-2 @@ -421,7 +421,7 @@ GTID_CURRENT_POS 0-2-21,1-3-4,2-1-3,3-1-2,4-3-2 GTID_SLAVE_POS 0-2-21,1-3-4,2-1-2,4-3-2 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 , ignore_domain_ids=(2,3); +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 , ignore_domain_ids=(2,3); SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-18,1-3-4,2-1-3,3-1-2,4-3-2 @@ -520,7 +520,7 @@ GTID_CURRENT_POS 0-1-26,1-3-4,2-1-3,3-1-2,4-3-2 GTID_SLAVE_POS 0-1-26,1-3-4,2-1-3,3-1-2,4-3-2 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 , ignore_domain_ids=(2,3); +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 , ignore_domain_ids=(2,3); SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-26,1-3-4,2-1-3,3-1-2,4-3-2 @@ -585,7 +585,7 @@ GTID_CURRENT_POS 0-2-29,1-3-4,2-1-3,3-1-2,4-3-2 GTID_SLAVE_POS 0-2-29,1-3-4,2-1-3,3-1-2,4-3-2 # First ensure gtid_slave_pos after master_demote_to_slave matches # gtid_current_pos calculation -CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_use_gtid=slave_pos, master_demote_to_slave=1 , ignore_domain_ids=(2,3); +CHANGE MASTER TO master_host='127.0.0.1', master_port=SLAVE_PORT, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos, master_demote_to_slave=1 , ignore_domain_ids=(2,3); SELECT VARIABLE_NAME, GLOBAL_VALUE FROM INFORMATION_SCHEMA.SYSTEM_VARIABLES WHERE VARIABLE_NAME LIKE 'gtid_binlog_pos' OR VARIABLE_NAME LIKE 'gtid_slave_pos' OR VARIABLE_NAME LIKE 'gtid_current_pos' ORDER BY VARIABLE_NAME ASC; VARIABLE_NAME GLOBAL_VALUE GTID_BINLOG_POS 0-1-26,1-3-4,2-1-3,3-1-2,4-3-2 diff --git a/mysql-test/suite/rpl/r/rpl_circular_semi_sync.result b/mysql-test/suite/rpl/r/rpl_circular_semi_sync.result index 5664b7913d2..6f64ca9ca24 100644 --- a/mysql-test/suite/rpl/r/rpl_circular_semi_sync.result +++ b/mysql-test/suite/rpl/r/rpl_circular_semi_sync.result @@ -30,7 +30,7 @@ include/sync_with_master_gtid.inc connection server_1; set @@global.gtid_strict_mode = true; set @@global.rpl_semi_sync_slave_enabled = 1; -CHANGE MASTER TO master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_use_gtid=SLAVE_POS; +CHANGE MASTER TO master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=SLAVE_POS; include/start_slave.inc ... is done. ## A. no out-of-order gtid error for own transaction made round trip diff --git a/mysql-test/suite/rpl/r/rpl_connection.result b/mysql-test/suite/rpl/r/rpl_connection.result index 9fb17b5f174..4ca15c47bc8 100644 --- a/mysql-test/suite/rpl/r/rpl_connection.result +++ b/mysql-test/suite/rpl/r/rpl_connection.result @@ -8,5 +8,5 @@ START SLAVE; include/wait_for_slave_io_error.inc [errno=1045, 1593] include/stop_slave_sql.inc CHANGE MASTER TO MASTER_USER= 'root', MASTER_PASSWORD= ''; -START SLAVE; +include/start_slave.inc include/rpl_end.inc diff --git a/mysql-test/suite/rpl/r/rpl_gtid_master_promote.result b/mysql-test/suite/rpl/r/rpl_gtid_master_promote.result index 92430be199a..af562e93876 100644 --- a/mysql-test/suite/rpl/r/rpl_gtid_master_promote.result +++ b/mysql-test/suite/rpl/r/rpl_gtid_master_promote.result @@ -335,7 +335,8 @@ a b *** Now let the old master join up as slave. *** connection server_1; CHANGE MASTER TO master_host = '127.0.0.1', master_port = SERVER_MYPORT_2, -master_user = "root", master_use_gtid = slave_pos, master_demote_to_slave=1; +master_user = "root", master_ssl_verify_server_cert=0, +master_use_gtid = slave_pos, master_demote_to_slave=1; include/start_slave.inc SELECT * FROM t1 ORDER BY a; a diff --git a/mysql-test/suite/rpl/r/rpl_gtid_mdev4473.result b/mysql-test/suite/rpl/r/rpl_gtid_mdev4473.result index 9524dafb524..c2a1cd28585 100644 --- a/mysql-test/suite/rpl/r/rpl_gtid_mdev4473.result +++ b/mysql-test/suite/rpl/r/rpl_gtid_mdev4473.result @@ -12,7 +12,8 @@ include/wait_for_slave_to_stop.inc reset slave all; connection server_1; CHANGE MASTER TO master_host = '127.0.0.1', master_port = SERVER_MYPORT_2, -master_user='root', MASTER_USE_GTID=SLAVE_POS, master_demote_to_slave=1; +master_user='root', master_ssl_verify_server_cert=0, +MASTER_USE_GTID=SLAVE_POS, master_demote_to_slave=1; include/start_slave.inc include/wait_for_slave_to_start.inc connection server_2; diff --git a/mysql-test/suite/rpl/r/rpl_gtid_mdev4485.result b/mysql-test/suite/rpl/r/rpl_gtid_mdev4485.result index 58953491ba3..fee14722bea 100644 --- a/mysql-test/suite/rpl/r/rpl_gtid_mdev4485.result +++ b/mysql-test/suite/rpl/r/rpl_gtid_mdev4485.result @@ -6,7 +6,7 @@ connection server_2; create table t2 (i int); connection server_3; set default_master_connection = 'm2'; -change master to master_host='127.0.0.1', master_port=SERVER_MYPORT_2, master_user='root', master_use_gtid=slave_pos; +change master to master_host='127.0.0.1', master_port=SERVER_MYPORT_2, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; include/start_slave.inc connection server_2; insert into t2 values (1); diff --git a/mysql-test/suite/rpl/r/rpl_gtid_mdev4820.result b/mysql-test/suite/rpl/r/rpl_gtid_mdev4820.result index 0eb9a0e9e24..01920c8ad89 100644 --- a/mysql-test/suite/rpl/r/rpl_gtid_mdev4820.result +++ b/mysql-test/suite/rpl/r/rpl_gtid_mdev4820.result @@ -44,7 +44,7 @@ RESET MASTER; SET GLOBAL gtid_slave_pos= '0-2-10'; connection server_1; CHANGE MASTER TO master_host = '127.0.0.1', master_port = SERVER_MYPORT_2, -master_user= 'root', master_use_gtid=CURRENT_POS; +master_user= 'root', master_ssl_verify_server_cert=0, master_use_gtid=CURRENT_POS; Warnings: Warning 1287 'master_use_gtid=current_pos' is deprecated and will be removed in a future release. Please use master_demote_to_slave=1 instead START SLAVE; diff --git a/mysql-test/suite/rpl/r/rpl_gtid_nobinlog.result b/mysql-test/suite/rpl/r/rpl_gtid_nobinlog.result index 8b896560d39..6a31eedccec 100644 --- a/mysql-test/suite/rpl/r/rpl_gtid_nobinlog.result +++ b/mysql-test/suite/rpl/r/rpl_gtid_nobinlog.result @@ -20,8 +20,8 @@ a b 2 1 include/stop_slave.inc connection server_1; -CHANGE MASTER TO master_host = '127.0.0.1', master_port = SLAVE_PORT, -master_user = 'root'; +CHANGE MASTER TO master_host = '127.0.0.1', master_port = SLAVE_PORT, master_ssl_verify_server_cert=0, +master_user = 'root', master_ssl_verify_server_cert=0; START SLAVE; include/wait_for_slave_to_start.inc connection server_2; @@ -50,7 +50,7 @@ INSERT INTO t1 VALUES (5, 1); INSERT INTO t1 VALUES (6, 1); include/save_master_gtid.inc connection server_2; -CHANGE MASTER TO master_host = '127.0.0.1', master_port = MASTER_PORT; +CHANGE MASTER TO master_host = '127.0.0.1', master_port = MASTER_PORT, master_ssl_verify_server_cert=0; START SLAVE; include/sync_with_master_gtid.inc SELECT * FROM t1 ORDER BY a; diff --git a/mysql-test/suite/rpl/r/rpl_heartbeat.result b/mysql-test/suite/rpl/r/rpl_heartbeat.result index 2a578245400..887df2ee03b 100644 --- a/mysql-test/suite/rpl/r/rpl_heartbeat.result +++ b/mysql-test/suite/rpl/r/rpl_heartbeat.result @@ -51,7 +51,7 @@ connection master; drop table if exists t1; connection slave; set @@global.slave_net_timeout= 10; -change master to master_host='127.0.0.1',master_port=MASTER_PORT, master_user='root', master_heartbeat_period= 0.5; +change master to master_host='127.0.0.1',master_port=MASTER_PORT, master_user='root', master_ssl_verify_server_cert=0, master_heartbeat_period= 0.5; show status like 'Slave_heartbeat_period';; Variable_name Slave_heartbeat_period Value 0.500 diff --git a/mysql-test/suite/rpl/r/rpl_heartbeat_ssl.result b/mysql-test/suite/rpl/r/rpl_heartbeat_ssl.result index 533290d25ca..7f11b85614a 100644 --- a/mysql-test/suite/rpl/r/rpl_heartbeat_ssl.result +++ b/mysql-test/suite/rpl/r/rpl_heartbeat_ssl.result @@ -24,7 +24,7 @@ Heartbeat event has received *** Clean up *** include/stop_slave.inc CHANGE MASTER TO -MASTER_SSL=0, +MASTER_SSL=1, MASTER_SSL_CA='', MASTER_SSL_CERT='', MASTER_SSL_KEY=''; diff --git a/mysql-test/suite/rpl/r/rpl_ipv4_as_ipv6.result b/mysql-test/suite/rpl/r/rpl_ipv4_as_ipv6.result index b1b16fb0738..5ad4b3eacc5 100644 --- a/mysql-test/suite/rpl/r/rpl_ipv4_as_ipv6.result +++ b/mysql-test/suite/rpl/r/rpl_ipv4_as_ipv6.result @@ -105,4 +105,4 @@ change master to master_host='127.0.0.1'; Master-Host: 127.0.0.1 change master to master_host='0:0000:0000:0:0000:FFFF:127.0.0.1'; Master-Host: 0:0000:0000:0:0000:FFFF:127.0.0.1 -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; diff --git a/mysql-test/suite/rpl/r/rpl_ipv6.result b/mysql-test/suite/rpl/r/rpl_ipv6.result index f1c5619b66b..fc9171d8b37 100644 --- a/mysql-test/suite/rpl/r/rpl_ipv6.result +++ b/mysql-test/suite/rpl/r/rpl_ipv6.result @@ -60,4 +60,4 @@ change master to master_host='127.0.0.1'; Master-Host: 127.0.0.1 change master to master_host='0:0:0:0:0:0:0:1'; Master-Host: 0:0:0:0:0:0:0:1 -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; diff --git a/mysql-test/suite/rpl/r/rpl_master_pos_wait.result b/mysql-test/suite/rpl/r/rpl_master_pos_wait.result index aae3418b546..4d19d81d407 100644 --- a/mysql-test/suite/rpl/r/rpl_master_pos_wait.result +++ b/mysql-test/suite/rpl/r/rpl_master_pos_wait.result @@ -27,7 +27,7 @@ NULL connection slave; include/stop_slave.inc reset slave all; -change master 'my_slave' to master_port=MASTER_MYPORT, master_host='127.0.0.1', master_user='root'; +change master 'my_slave' to master_port=MASTER_MYPORT, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; set default_master_connection = 'my_slave'; include/start_slave.inc # Call without connection name -- works (expected -1) diff --git a/mysql-test/suite/rpl/r/rpl_perfschema_applier_status_by_worker.result b/mysql-test/suite/rpl/r/rpl_perfschema_applier_status_by_worker.result index 268ab0104a6..8180d0c0f44 100644 --- a/mysql-test/suite/rpl/r/rpl_perfschema_applier_status_by_worker.result +++ b/mysql-test/suite/rpl/r/rpl_perfschema_applier_status_by_worker.result @@ -10,7 +10,7 @@ include/stop_slave.inc set @save_slave_parallel_workers= @@global.slave_parallel_workers; set @save_slave_transaction_retries= @@global.slave_transaction_retries; RESET SLAVE ALL; -CHANGE MASTER 'slave1' TO MASTER_USER='root',MASTER_PORT=$MASTER_MYPORT, MASTER_HOST='127.0.0.1', MASTER_USE_GTID=slave_pos; +CHANGE MASTER 'slave1' TO MASTER_USER='root',MASTER_PORT=$MASTER_MYPORT, MASTER_HOST='127.0.0.1', MASTER_USE_GTID=slave_pos, MASTER_SSL_VERIFY_SERVER_CERT=0; SET default_master_connection='slave1'; SET @@global.slave_parallel_workers=1; ALTER TABLE mysql.gtid_slave_pos ENGINE=InnoDB; diff --git a/mysql-test/suite/rpl/r/rpl_perfschema_connect_config.result b/mysql-test/suite/rpl/r/rpl_perfschema_connect_config.result index d45fc2397f7..027c3b14273 100644 --- a/mysql-test/suite/rpl/r/rpl_perfschema_connect_config.result +++ b/mysql-test/suite/rpl/r/rpl_perfschema_connect_config.result @@ -67,7 +67,7 @@ master_ssl_ca= '', master_ssl_cert= '', master_ssl_key= '', master_ssl_verify_server_cert=0, -master_ssl=0, +master_ssl=1, master_use_gtid=no; include/start_slave.inc diff --git a/mysql-test/suite/rpl/r/rpl_rewrite_db_sys_vars.result b/mysql-test/suite/rpl/r/rpl_rewrite_db_sys_vars.result index 5720f647b90..f755ce7901e 100644 --- a/mysql-test/suite/rpl/r/rpl_rewrite_db_sys_vars.result +++ b/mysql-test/suite/rpl/r/rpl_rewrite_db_sys_vars.result @@ -134,7 +134,7 @@ connection slave; include/stop_slave.inc include/reset_slave.inc include/rpl_restart_server.inc [server_number=2] -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=MASTER_MYPORT, MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=MASTER_MYPORT, MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; connection slave; include/start_slave.inc SELECT @@GLOBAL.replicate_rewrite_db; diff --git a/mysql-test/suite/rpl/r/rpl_rotate_logs.result b/mysql-test/suite/rpl/r/rpl_rotate_logs.result index d720b0b865e..4b7c1642a11 100644 --- a/mysql-test/suite/rpl/r/rpl_rotate_logs.result +++ b/mysql-test/suite/rpl/r/rpl_rotate_logs.result @@ -10,7 +10,7 @@ ERROR HY000: Could not initialize master info structure for ''; more error messa change master to master_host='127.0.0.1',master_port=MASTER_PORT, master_user='root'; ERROR HY000: Could not initialize master info structure for ''; more error messages can be found in the MariaDB error log reset slave; -change master to master_host='127.0.0.1',master_port=MASTER_PORT, master_user='root'; +change master to master_host='127.0.0.1',master_port=MASTER_PORT, master_user='root', master_ssl_verify_server_cert=0; connection master; reset master; connection slave; diff --git a/mysql-test/suite/rpl/r/rpl_semi_sync_fail_over.result b/mysql-test/suite/rpl/r/rpl_semi_sync_fail_over.result index 8956eee2d2f..9b02d7acea1 100644 --- a/mysql-test/suite/rpl/r/rpl_semi_sync_fail_over.result +++ b/mysql-test/suite/rpl/r/rpl_semi_sync_fail_over.result @@ -57,7 +57,7 @@ connection server_2; set global rpl_semi_sync_master_enabled = 1; set global rpl_semi_sync_master_wait_point=AFTER_SYNC; connection server_1; -CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_use_gtid=SLAVE_POS; +CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=SLAVE_POS; set global rpl_semi_sync_slave_enabled = 1; set @@global.gtid_slave_pos=@@global.gtid_binlog_pos; include/start_slave.inc @@ -135,7 +135,7 @@ connection server_1; set global rpl_semi_sync_master_enabled = 1; set global rpl_semi_sync_master_wait_point=AFTER_SYNC; connection server_2; -CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_use_gtid=SLAVE_POS; +CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=SLAVE_POS; set global rpl_semi_sync_slave_enabled = 1; set @@global.gtid_slave_pos=@@global.gtid_binlog_pos; include/start_slave.inc @@ -214,7 +214,7 @@ connection server_2; set global rpl_semi_sync_master_enabled = 1; set global rpl_semi_sync_master_wait_point=AFTER_SYNC; connection server_1; -CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_use_gtid=SLAVE_POS; +CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=SLAVE_POS; set global rpl_semi_sync_slave_enabled = 1; set @@global.gtid_slave_pos=@@global.gtid_binlog_pos; include/start_slave.inc diff --git a/mysql-test/suite/rpl/r/rpl_semisync_ali_issues.result b/mysql-test/suite/rpl/r/rpl_semisync_ali_issues.result index f5e1c8d31b9..47ea3aea689 100644 --- a/mysql-test/suite/rpl/r/rpl_semisync_ali_issues.result +++ b/mysql-test/suite/rpl/r/rpl_semisync_ali_issues.result @@ -344,6 +344,4 @@ SET GLOBAL rpl_semi_sync_master_enabled = 0; DROP TABLE t1; connection slave; SET GLOBAL rpl_semi_sync_slave_enabled = 0; -stop slave; -start slave; include/rpl_end.inc diff --git a/mysql-test/suite/rpl/r/rpl_set_statement_default_master.result b/mysql-test/suite/rpl/r/rpl_set_statement_default_master.result index 46f5a7c927e..8681d67f469 100644 --- a/mysql-test/suite/rpl/r/rpl_set_statement_default_master.result +++ b/mysql-test/suite/rpl/r/rpl_set_statement_default_master.result @@ -11,7 +11,9 @@ CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=MASTER_MYPORT, MASTER_USER # Connection_name = 'm1' RESET SLAVE ALL; -CHANGE MASTER 'm1' TO MASTER_HOST='127.0.0.1', MASTER_PORT=MASTER_MYPORT, MASTER_USER='root'; +CHANGE MASTER 'm1' TO MASTER_HOST='127.0.0.1', +MASTER_PORT=MASTER_MYPORT, MASTER_USER='root', +MASTER_SSL_VERIFY_SERVER_CERT=0; SET STATEMENT default_master_connection = 'm1' FOR START SLAVE; set default_master_connection = 'm1'; include/wait_for_slave_to_start.inc diff --git a/mysql-test/suite/rpl/r/rpl_show_slave_hosts.result b/mysql-test/suite/rpl/r/rpl_show_slave_hosts.result index 79803cca0d0..0c8903378a7 100644 --- a/mysql-test/suite/rpl/r/rpl_show_slave_hosts.result +++ b/mysql-test/suite/rpl/r/rpl_show_slave_hosts.result @@ -3,7 +3,7 @@ include/master-slave.inc connect slave2,127.0.0.1,root,,test,$SLAVE_MYPORT2,; connection slave2; RESET SLAVE; -CHANGE MASTER TO master_host='127.0.0.1',master_port=MASTER_PORT,master_user='root'; +CHANGE MASTER TO master_host='127.0.0.1',master_port=MASTER_PORT,master_user='root', master_ssl_verify_server_cert=0; START SLAVE IO_THREAD; include/wait_for_slave_io_to_start.inc connection master; diff --git a/mysql-test/suite/rpl/r/rpl_slave_shutdown_mdev20821.result b/mysql-test/suite/rpl/r/rpl_slave_shutdown_mdev20821.result index f90d2126103..4d0c81f42a8 100644 --- a/mysql-test/suite/rpl/r/rpl_slave_shutdown_mdev20821.result +++ b/mysql-test/suite/rpl/r/rpl_slave_shutdown_mdev20821.result @@ -5,7 +5,7 @@ include/start_slave.inc Warnings: Note 1254 Slave is already running set default_master_connection = 'm2'; -change master to master_host='127.0.0.1', master_port=SERVER_MYPORT_2, master_user='root', master_use_gtid=slave_pos; +change master to master_host='127.0.0.1', master_port=SERVER_MYPORT_2, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; include/start_slave.inc select @@global.slave_parallel_workers as two; two diff --git a/mysql-test/suite/rpl/r/rpl_ssl.result b/mysql-test/suite/rpl/r/rpl_ssl.result index ce9e4d486cf..8c696f25752 100644 --- a/mysql-test/suite/rpl/r/rpl_ssl.result +++ b/mysql-test/suite/rpl/r/rpl_ssl.result @@ -51,7 +51,7 @@ connection slave; include/stop_slave.inc CHANGE MASTER TO master_user = 'root', -master_ssl = 0, +master_ssl = 1, master_ssl_ca = '', master_ssl_cert = '', master_ssl_key = ''; diff --git a/mysql-test/suite/rpl/r/rpl_ssl1.result b/mysql-test/suite/rpl/r/rpl_ssl1.result index a480f51053a..c6721d2f466 100644 --- a/mysql-test/suite/rpl/r/rpl_ssl1.result +++ b/mysql-test/suite/rpl/r/rpl_ssl1.result @@ -7,7 +7,7 @@ create table t1 (t int); connection slave; stop slave; include/wait_for_slave_to_stop.inc -change master to master_user='replssl',master_password=''; +change master to master_user='replssl',master_password='',master_ssl=0; start slave; connection master; insert into t1 values (1); @@ -108,7 +108,7 @@ master_ssl_ca ='', master_ssl_cert='', master_ssl_key='', master_ssl_verify_server_cert=0, -master_ssl=0; +master_ssl=1; connection master; drop user replssl@127.0.0.1; connection slave; diff --git a/mysql-test/suite/rpl/r/rpl_start_alter_restart_slave.result b/mysql-test/suite/rpl/r/rpl_start_alter_restart_slave.result index a0a368399fb..eecb4212f4b 100644 --- a/mysql-test/suite/rpl/r/rpl_start_alter_restart_slave.result +++ b/mysql-test/suite/rpl/r/rpl_start_alter_restart_slave.result @@ -110,10 +110,10 @@ set global binlog_alter_two_phase = 0; SET GLOBAL debug_dbug= @old_debug_master; set DEBUG_SYNC= 'RESET'; connection slave; -stop slave; +include/stop_slave.inc set global slave_parallel_threads = 0;; set global slave_parallel_mode = optimistic;; set global gtid_strict_mode = 0;; set DEBUG_SYNC= 'RESET'; -start slave; +include/start_slave.inc include/rpl_end.inc diff --git a/mysql-test/suite/rpl/r/rpl_upgrade_master_info.result b/mysql-test/suite/rpl/r/rpl_upgrade_master_info.result index 1babddf9a6e..08a0a6a4202 100644 --- a/mysql-test/suite/rpl/r/rpl_upgrade_master_info.result +++ b/mysql-test/suite/rpl/r/rpl_upgrade_master_info.result @@ -90,7 +90,7 @@ connection master; INSERT INTO t1 VALUES (6); include/save_master_gtid.inc connection slave; -CHANGE MASTER TO master_host='127.0.0.1', master_port=SERVER_MYPORT_1; +CHANGE MASTER TO master_host='127.0.0.1', master_port=SERVER_MYPORT_1, MASTER_SSL=1; include/start_slave.inc include/sync_with_master_gtid.inc SELECT * FROM t1 ORDER BY a; diff --git a/mysql-test/suite/rpl/r/show_status_stop_slave_race-7126.result b/mysql-test/suite/rpl/r/show_status_stop_slave_race-7126.result index 999d9417b3f..298a3daf64a 100644 --- a/mysql-test/suite/rpl/r/show_status_stop_slave_race-7126.result +++ b/mysql-test/suite/rpl/r/show_status_stop_slave_race-7126.result @@ -4,6 +4,6 @@ call mtr.add_suppression("Master is configured to log replication events"); connection slave; connection slave; include/wait_for_slave_to_stop.inc -start slave; +include/start_slave.inc connection master; include/rpl_end.inc diff --git a/mysql-test/suite/rpl/t/grant_replication_slave.test b/mysql-test/suite/rpl/t/grant_replication_slave.test index c5aca0a60e1..d50e8a1327d 100644 --- a/mysql-test/suite/rpl/t/grant_replication_slave.test +++ b/mysql-test/suite/rpl/t/grant_replication_slave.test @@ -33,7 +33,7 @@ drop database mysqltest1; sync_slave_with_master; stop slave; change master to master_user='root'; -start slave; +source include/start_slave.inc; source include/rpl_end.inc; drop user rpl@localhost; diff --git a/mysql-test/suite/rpl/t/rpl_000010.test b/mysql-test/suite/rpl/t/rpl_000010.test index 9ff2d6c562d..27b29017b75 100644 --- a/mysql-test/suite/rpl/t/rpl_000010.test +++ b/mysql-test/suite/rpl/t/rpl_000010.test @@ -17,6 +17,7 @@ select n from t1; connection master; drop table t1; sync_slave_with_master; +source include/wait_for_slave_to_start.inc; # End of 4.1 tests --source include/rpl_end.inc diff --git a/mysql-test/suite/rpl/t/rpl_circular_semi_sync.test b/mysql-test/suite/rpl/t/rpl_circular_semi_sync.test index 267fa621945..19b6a80fce1 100644 --- a/mysql-test/suite/rpl/t/rpl_circular_semi_sync.test +++ b/mysql-test/suite/rpl/t/rpl_circular_semi_sync.test @@ -52,7 +52,7 @@ INSERT INTO t1(a) VALUES (1); set @@global.gtid_strict_mode = true; set @@global.rpl_semi_sync_slave_enabled = 1; -evalp CHANGE MASTER TO master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_use_gtid=SLAVE_POS; +evalp CHANGE MASTER TO master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=SLAVE_POS; --source include/start_slave.inc --echo ... is done. diff --git a/mysql-test/suite/rpl/t/rpl_connection.test b/mysql-test/suite/rpl/t/rpl_connection.test index 24ada7c85c6..5ad076de043 100644 --- a/mysql-test/suite/rpl/t/rpl_connection.test +++ b/mysql-test/suite/rpl/t/rpl_connection.test @@ -19,6 +19,6 @@ START SLAVE; --source include/stop_slave_sql.inc CHANGE MASTER TO MASTER_USER= 'root', MASTER_PASSWORD= ''; -START SLAVE; +--source include/start_slave.inc --source include/rpl_end.inc diff --git a/mysql-test/suite/rpl/t/rpl_gtid_master_promote.test b/mysql-test/suite/rpl/t/rpl_gtid_master_promote.test index 064c70b123d..5e2470ed95e 100644 --- a/mysql-test/suite/rpl/t/rpl_gtid_master_promote.test +++ b/mysql-test/suite/rpl/t/rpl_gtid_master_promote.test @@ -221,7 +221,8 @@ SELECT * FROM t4 ORDER BY a,b; --connection server_1 --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_2, - master_user = "root", master_use_gtid = slave_pos, master_demote_to_slave=1; + master_user = "root", master_ssl_verify_server_cert=0, + master_use_gtid = slave_pos, master_demote_to_slave=1; --source include/start_slave.inc --sync_with_master SELECT * FROM t1 ORDER BY a; diff --git a/mysql-test/suite/rpl/t/rpl_gtid_mdev4473.test b/mysql-test/suite/rpl/t/rpl_gtid_mdev4473.test index f52e51c2413..396ea5deba8 100644 --- a/mysql-test/suite/rpl/t/rpl_gtid_mdev4473.test +++ b/mysql-test/suite/rpl/t/rpl_gtid_mdev4473.test @@ -24,7 +24,8 @@ reset slave all; connection server_1; --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_2, - master_user='root', MASTER_USE_GTID=SLAVE_POS, master_demote_to_slave=1; + master_user='root', master_ssl_verify_server_cert=0, + MASTER_USE_GTID=SLAVE_POS, master_demote_to_slave=1; source include/start_slave.inc; source include/wait_for_slave_to_start.inc; diff --git a/mysql-test/suite/rpl/t/rpl_gtid_mdev4485.test b/mysql-test/suite/rpl/t/rpl_gtid_mdev4485.test index 6c37ceaff31..7ee811bafca 100644 --- a/mysql-test/suite/rpl/t/rpl_gtid_mdev4485.test +++ b/mysql-test/suite/rpl/t/rpl_gtid_mdev4485.test @@ -13,7 +13,7 @@ create table t2 (i int); set default_master_connection = 'm2'; --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2 -eval change master to master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_use_gtid=slave_pos; +eval change master to master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --source include/start_slave.inc --connection server_2 diff --git a/mysql-test/suite/rpl/t/rpl_gtid_mdev4820.test b/mysql-test/suite/rpl/t/rpl_gtid_mdev4820.test index 7f4d851f95c..79b3b7d464a 100644 --- a/mysql-test/suite/rpl/t/rpl_gtid_mdev4820.test +++ b/mysql-test/suite/rpl/t/rpl_gtid_mdev4820.test @@ -59,7 +59,7 @@ SET GLOBAL gtid_slave_pos= '0-2-10'; --connection server_1 --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2 eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SERVER_MYPORT_2, - master_user= 'root', master_use_gtid=CURRENT_POS; + master_user= 'root', master_ssl_verify_server_cert=0, master_use_gtid=CURRENT_POS; START SLAVE; --connection server_2 diff --git a/mysql-test/suite/rpl/t/rpl_gtid_nobinlog.test b/mysql-test/suite/rpl/t/rpl_gtid_nobinlog.test index e140f335963..48627a6d5ff 100644 --- a/mysql-test/suite/rpl/t/rpl_gtid_nobinlog.test +++ b/mysql-test/suite/rpl/t/rpl_gtid_nobinlog.test @@ -24,8 +24,8 @@ SELECT * FROM t1 ORDER BY a; --connection server_1 --replace_result $SLAVE_MYPORT SLAVE_PORT -eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SLAVE_MYPORT, - master_user = 'root'; +eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $SLAVE_MYPORT, master_ssl_verify_server_cert=0, + master_user = 'root', master_ssl_verify_server_cert=0; START SLAVE; --source include/wait_for_slave_to_start.inc @@ -49,7 +49,7 @@ INSERT INTO t1 VALUES (6, 1); --connection server_2 --replace_result $MASTER_MYPORT MASTER_PORT -eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $MASTER_MYPORT; +eval CHANGE MASTER TO master_host = '127.0.0.1', master_port = $MASTER_MYPORT, master_ssl_verify_server_cert=0; START SLAVE; --source include/sync_with_master_gtid.inc diff --git a/mysql-test/suite/rpl/t/rpl_heartbeat.test b/mysql-test/suite/rpl/t/rpl_heartbeat.test index e4753b7be07..a04ba4c58e4 100644 --- a/mysql-test/suite/rpl/t/rpl_heartbeat.test +++ b/mysql-test/suite/rpl/t/rpl_heartbeat.test @@ -107,7 +107,7 @@ connection slave; set @@global.slave_net_timeout= 10; --replace_result $MASTER_MYPORT MASTER_PORT # no error this time but rather a warning -eval change master to master_host='127.0.0.1',master_port=$MASTER_MYPORT, master_user='root', master_heartbeat_period= 0.5; +eval change master to master_host='127.0.0.1',master_port=$MASTER_MYPORT, master_user='root', master_ssl_verify_server_cert=0, master_heartbeat_period= 0.5; --query_vertical show status like 'Slave_heartbeat_period'; start slave; diff --git a/mysql-test/suite/rpl/t/rpl_heartbeat_ssl.test b/mysql-test/suite/rpl/t/rpl_heartbeat_ssl.test index 2c41fdeeca8..156294eefd0 100644 --- a/mysql-test/suite/rpl/t/rpl_heartbeat_ssl.test +++ b/mysql-test/suite/rpl/t/rpl_heartbeat_ssl.test @@ -49,7 +49,7 @@ let $status_var_comparsion= >; --echo *** Clean up *** --source include/stop_slave.inc CHANGE MASTER TO - MASTER_SSL=0, + MASTER_SSL=1, MASTER_SSL_CA='', MASTER_SSL_CERT='', MASTER_SSL_KEY=''; diff --git a/mysql-test/suite/rpl/t/rpl_ipv4_as_ipv6.test b/mysql-test/suite/rpl/t/rpl_ipv4_as_ipv6.test index d17b32c321f..2988cac9bf6 100644 --- a/mysql-test/suite/rpl/t/rpl_ipv4_as_ipv6.test +++ b/mysql-test/suite/rpl/t/rpl_ipv4_as_ipv6.test @@ -60,4 +60,4 @@ let $master_host= query_get_value(SHOW SLAVE STATUS, Master_Host, 1); --echo Master-Host: $master_host # clean up -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; diff --git a/mysql-test/suite/rpl/t/rpl_ipv6.test b/mysql-test/suite/rpl/t/rpl_ipv6.test index f379583212e..c68255a189e 100644 --- a/mysql-test/suite/rpl/t/rpl_ipv6.test +++ b/mysql-test/suite/rpl/t/rpl_ipv6.test @@ -46,4 +46,4 @@ let $master_host= query_get_value(SHOW SLAVE STATUS, Master_Host, 1); --echo Master-Host: $master_host # clean up -CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root'; +CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; diff --git a/mysql-test/suite/rpl/t/rpl_master_pos_wait.test b/mysql-test/suite/rpl/t/rpl_master_pos_wait.test index 437d8412086..e815502d22f 100644 --- a/mysql-test/suite/rpl/t/rpl_master_pos_wait.test +++ b/mysql-test/suite/rpl/t/rpl_master_pos_wait.test @@ -34,7 +34,7 @@ select master_pos_wait('foo', 98); --source include/stop_slave.inc reset slave all; --replace_result $MASTER_MYPORT MASTER_MYPORT -eval change master 'my_slave' to master_port=$MASTER_MYPORT, master_host='127.0.0.1', master_user='root'; +eval change master 'my_slave' to master_port=$MASTER_MYPORT, master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0; set default_master_connection = 'my_slave'; --source include/start_slave.inc diff --git a/mysql-test/suite/rpl/t/rpl_perfschema_applier_status_by_worker.test b/mysql-test/suite/rpl/t/rpl_perfschema_applier_status_by_worker.test index 5ef28a62006..72559fc4090 100644 --- a/mysql-test/suite/rpl/t/rpl_perfschema_applier_status_by_worker.test +++ b/mysql-test/suite/rpl/t/rpl_perfschema_applier_status_by_worker.test @@ -52,7 +52,7 @@ set @save_slave_parallel_workers= @@global.slave_parallel_workers; # to avoid warnings set @save_slave_transaction_retries= @@global.slave_transaction_retries; RESET SLAVE ALL; -evalp CHANGE MASTER 'slave1' TO MASTER_USER='root',MASTER_PORT=$MASTER_MYPORT, MASTER_HOST='127.0.0.1', MASTER_USE_GTID=slave_pos; +evalp CHANGE MASTER 'slave1' TO MASTER_USER='root',MASTER_PORT=$MASTER_MYPORT, MASTER_HOST='127.0.0.1', MASTER_USE_GTID=slave_pos, MASTER_SSL_VERIFY_SERVER_CERT=0; SET default_master_connection='slave1'; SET @@global.slave_parallel_workers=1; ALTER TABLE mysql.gtid_slave_pos ENGINE=InnoDB; diff --git a/mysql-test/suite/rpl/t/rpl_perfschema_connect_config.test b/mysql-test/suite/rpl/t/rpl_perfschema_connect_config.test index 244495c0b9e..e2b974c156a 100644 --- a/mysql-test/suite/rpl/t/rpl_perfschema_connect_config.test +++ b/mysql-test/suite/rpl/t/rpl_perfschema_connect_config.test @@ -231,7 +231,7 @@ CHANGE MASTER TO master_ssl_cert= '', master_ssl_key= '', master_ssl_verify_server_cert=0, - master_ssl=0, + master_ssl=1, master_use_gtid=no; --source include/start_slave.inc diff --git a/mysql-test/suite/rpl/t/rpl_rewrite_db_sys_vars.test b/mysql-test/suite/rpl/t/rpl_rewrite_db_sys_vars.test index 27710063792..b64c2e1a7df 100644 --- a/mysql-test/suite/rpl/t/rpl_rewrite_db_sys_vars.test +++ b/mysql-test/suite/rpl/t/rpl_rewrite_db_sys_vars.test @@ -134,7 +134,7 @@ connection slave; --let $rpl_server_number= 2 --source include/rpl_restart_server.inc --replace_result $MASTER_MYPORT MASTER_MYPORT -eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=$MASTER_MYPORT, MASTER_USER='root'; +eval CHANGE MASTER TO MASTER_HOST='127.0.0.1', MASTER_PORT=$MASTER_MYPORT, MASTER_USER='root', MASTER_SSL_VERIFY_SERVER_CERT=0; # New value connection slave; diff --git a/mysql-test/suite/rpl/t/rpl_rotate_logs.test b/mysql-test/suite/rpl/t/rpl_rotate_logs.test index 4dd58931cd9..98016667d4f 100644 --- a/mysql-test/suite/rpl/t/rpl_rotate_logs.test +++ b/mysql-test/suite/rpl/t/rpl_rotate_logs.test @@ -50,7 +50,7 @@ start slave; eval change master to master_host='127.0.0.1',master_port=$MASTER_MYPORT, master_user='root'; reset slave; --replace_result $MASTER_MYPORT MASTER_PORT -eval change master to master_host='127.0.0.1',master_port=$MASTER_MYPORT, master_user='root'; +eval change master to master_host='127.0.0.1',master_port=$MASTER_MYPORT, master_user='root', master_ssl_verify_server_cert=0; connection master; reset master; connection slave; diff --git a/mysql-test/suite/rpl/t/rpl_semi_sync_crash.inc b/mysql-test/suite/rpl/t/rpl_semi_sync_crash.inc index 01b0d0e5050..0cedefd7dd7 100644 --- a/mysql-test/suite/rpl/t/rpl_semi_sync_crash.inc +++ b/mysql-test/suite/rpl/t/rpl_semi_sync_crash.inc @@ -106,7 +106,7 @@ if (`select $server_to_crash = 2`) { --let $master_port=$SERVER_MYPORT_1 } -evalp CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_use_gtid=SLAVE_POS; +evalp CHANGE MASTER TO master_host='127.0.0.1', master_port=$new_master_port, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=SLAVE_POS; set global rpl_semi_sync_slave_enabled = 1; set @@global.gtid_slave_pos=@@global.gtid_binlog_pos; --source include/start_slave.inc diff --git a/mysql-test/suite/rpl/t/rpl_semisync_ali_issues.test b/mysql-test/suite/rpl/t/rpl_semisync_ali_issues.test index 1337eca3422..dd4cb2fe62b 100644 --- a/mysql-test/suite/rpl/t/rpl_semisync_ali_issues.test +++ b/mysql-test/suite/rpl/t/rpl_semisync_ali_issues.test @@ -424,6 +424,5 @@ SET GLOBAL rpl_semi_sync_master_enabled = 0; DROP TABLE t1; connection slave; SET GLOBAL rpl_semi_sync_slave_enabled = 0; -stop slave;start slave; --source include/rpl_end.inc diff --git a/mysql-test/suite/rpl/t/rpl_set_statement_default_master.test b/mysql-test/suite/rpl/t/rpl_set_statement_default_master.test index d30da61bee6..e121e7ba23b 100644 --- a/mysql-test/suite/rpl/t/rpl_set_statement_default_master.test +++ b/mysql-test/suite/rpl/t/rpl_set_statement_default_master.test @@ -22,7 +22,9 @@ eval SET STATEMENT default_master_connection = 'm1' FOR RESET SLAVE ALL; --replace_result $MASTER_MYPORT MASTER_MYPORT -eval CHANGE MASTER 'm1' TO MASTER_HOST='127.0.0.1', MASTER_PORT=$MASTER_MYPORT, MASTER_USER='root'; +eval CHANGE MASTER 'm1' TO MASTER_HOST='127.0.0.1', + MASTER_PORT=$MASTER_MYPORT, MASTER_USER='root', + MASTER_SSL_VERIFY_SERVER_CERT=0; SET STATEMENT default_master_connection = 'm1' FOR START SLAVE; set default_master_connection = 'm1'; diff --git a/mysql-test/suite/rpl/t/rpl_show_slave_hosts.test b/mysql-test/suite/rpl/t/rpl_show_slave_hosts.test index 84c5c215a08..afac298495f 100644 --- a/mysql-test/suite/rpl/t/rpl_show_slave_hosts.test +++ b/mysql-test/suite/rpl/t/rpl_show_slave_hosts.test @@ -15,7 +15,7 @@ connect (slave2,127.0.0.1,root,,test,$SLAVE_MYPORT2,); connection slave2; RESET SLAVE; --replace_result $MASTER_MYPORT MASTER_PORT ---eval CHANGE MASTER TO master_host='127.0.0.1',master_port=$MASTER_MYPORT,master_user='root' +--eval CHANGE MASTER TO master_host='127.0.0.1',master_port=$MASTER_MYPORT,master_user='root', master_ssl_verify_server_cert=0 START SLAVE IO_THREAD; source include/wait_for_slave_io_to_start.inc; diff --git a/mysql-test/suite/rpl/t/rpl_slave_shutdown_mdev20821.test b/mysql-test/suite/rpl/t/rpl_slave_shutdown_mdev20821.test index 6f73de984d3..1179d7bfe3a 100644 --- a/mysql-test/suite/rpl/t/rpl_slave_shutdown_mdev20821.test +++ b/mysql-test/suite/rpl/t/rpl_slave_shutdown_mdev20821.test @@ -23,7 +23,7 @@ set default_master_connection = ''; set default_master_connection = 'm2'; --replace_result $SERVER_MYPORT_2 SERVER_MYPORT_2 -eval change master to master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_use_gtid=slave_pos; +eval change master to master_host='127.0.0.1', master_port=$SERVER_MYPORT_2, master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --source include/start_slave.inc select @@global.slave_parallel_workers as two; diff --git a/mysql-test/suite/rpl/t/rpl_ssl.test b/mysql-test/suite/rpl/t/rpl_ssl.test index 0420a6c8c2d..ad9a191d6b5 100644 --- a/mysql-test/suite/rpl/t/rpl_ssl.test +++ b/mysql-test/suite/rpl/t/rpl_ssl.test @@ -106,7 +106,7 @@ sync_slave_with_master; --source include/stop_slave.inc CHANGE MASTER TO master_user = 'root', - master_ssl = 0, + master_ssl = 1, master_ssl_ca = '', master_ssl_cert = '', master_ssl_key = ''; diff --git a/mysql-test/suite/rpl/t/rpl_ssl1.test b/mysql-test/suite/rpl/t/rpl_ssl1.test index 8734299f42f..0caaae251d1 100644 --- a/mysql-test/suite/rpl/t/rpl_ssl1.test +++ b/mysql-test/suite/rpl/t/rpl_ssl1.test @@ -16,7 +16,7 @@ sync_slave_with_master; #trying to use this user without ssl stop slave; --source include/wait_for_slave_to_stop.inc -change master to master_user='replssl',master_password=''; +change master to master_user='replssl',master_password='',master_ssl=0; start slave; #showing that replication don't work @@ -131,7 +131,7 @@ CHANGE MASTER TO master_ssl_cert='', master_ssl_key='', master_ssl_verify_server_cert=0, - master_ssl=0; + master_ssl=1; connection master; drop user replssl@127.0.0.1; connection slave; diff --git a/mysql-test/suite/rpl/t/rpl_start_alter_7.test b/mysql-test/suite/rpl/t/rpl_start_alter_7.test index 21c21c85c59..0e72b43e33f 100644 --- a/mysql-test/suite/rpl/t/rpl_start_alter_7.test +++ b/mysql-test/suite/rpl/t/rpl_start_alter_7.test @@ -36,9 +36,9 @@ set global gtid_strict_mode=1; --disable_warnings --disable_query_log --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --enable_query_log --enable_warnings diff --git a/mysql-test/suite/rpl/t/rpl_start_alter_8.test b/mysql-test/suite/rpl/t/rpl_start_alter_8.test index c8c5ac74404..ac7abca255e 100644 --- a/mysql-test/suite/rpl/t/rpl_start_alter_8.test +++ b/mysql-test/suite/rpl/t/rpl_start_alter_8.test @@ -35,9 +35,9 @@ set global gtid_strict_mode=1; --disable_warnings --disable_query_log --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval change master 'm1' to master_port=$SERVER_MYPORT_1 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_use_gtid=slave_pos; +eval change master 'm2' to master_port=$SERVER_MYPORT_2 , master_host='127.0.0.1', master_user='root', master_ssl_verify_server_cert=0, master_use_gtid=slave_pos; --enable_query_log --enable_warnings diff --git a/mysql-test/suite/rpl/t/rpl_start_alter_mysqlbinlog_2.test b/mysql-test/suite/rpl/t/rpl_start_alter_mysqlbinlog_2.test index 9d9675c6487..1cbc5b67fb9 100644 --- a/mysql-test/suite/rpl/t/rpl_start_alter_mysqlbinlog_2.test +++ b/mysql-test/suite/rpl/t/rpl_start_alter_mysqlbinlog_2.test @@ -71,9 +71,9 @@ SET GLOBAL gtid_strict_mode=1; --disable_warnings --disable_query_log --replace_result $SERVER_MYPORT_1 MYPORT_1 -eval CHANGE MASTER 'm1' TO MASTER_PORT=$SERVER_MYPORT_1, MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_USE_GTID=slave_pos; +eval CHANGE MASTER 'm1' TO MASTER_PORT=$SERVER_MYPORT_1, MASTER_HOST='127.0.0.1', MASTER_USER='root', master_ssl_verify_server_cert=0, MASTER_USE_GTID=slave_pos; --replace_result $SERVER_MYPORT_2 MYPORT_2 -eval CHANGE MASTER 'm2' TO MASTER_PORT=$SERVER_MYPORT_2, MASTER_HOST='127.0.0.1', MASTER_USER='root', MASTER_USE_GTID=slave_pos; +eval CHANGE MASTER 'm2' TO MASTER_PORT=$SERVER_MYPORT_2, MASTER_HOST='127.0.0.1', MASTER_USER='root', master_ssl_verify_server_cert=0, MASTER_USE_GTID=slave_pos; --enable_query_log --enable_warnings diff --git a/mysql-test/suite/rpl/t/rpl_start_alter_restart_slave.test b/mysql-test/suite/rpl/t/rpl_start_alter_restart_slave.test index 319e8223929..4485b77b171 100644 --- a/mysql-test/suite/rpl/t/rpl_start_alter_restart_slave.test +++ b/mysql-test/suite/rpl/t/rpl_start_alter_restart_slave.test @@ -6,8 +6,8 @@ # --source include/have_log_bin.inc --source include/have_innodb.inc ---source include/master-slave.inc --source include/have_debug.inc +--source include/master-slave.inc --connection slave SET @old_debug_slave= @@global.debug_dbug; @@ -112,10 +112,10 @@ SET GLOBAL debug_dbug= @old_debug_master; set DEBUG_SYNC= 'RESET'; --sync_slave_with_master -stop slave; +--source include/stop_slave.inc --eval set global slave_parallel_threads = $slave_parallel_threads; --eval set global slave_parallel_mode = $slave_parallel_mode; --eval set global gtid_strict_mode = $gtid_strict_mode; set DEBUG_SYNC= 'RESET'; -start slave; +--source include/start_slave.inc --source include/rpl_end.inc diff --git a/mysql-test/suite/rpl/t/rpl_upgrade_master_info.test b/mysql-test/suite/rpl/t/rpl_upgrade_master_info.test index fb0e3cf48f7..dc904166715 100644 --- a/mysql-test/suite/rpl/t/rpl_upgrade_master_info.test +++ b/mysql-test/suite/rpl/t/rpl_upgrade_master_info.test @@ -155,7 +155,7 @@ INSERT INTO t1 VALUES (6); --connection slave # Fix the port after we replaced master.info. --replace_result $SERVER_MYPORT_1 SERVER_MYPORT_1 -eval CHANGE MASTER TO master_host='127.0.0.1', master_port=$SERVER_MYPORT_1; +eval CHANGE MASTER TO master_host='127.0.0.1', master_port=$SERVER_MYPORT_1, MASTER_SSL=1; --source include/start_slave.inc --source include/sync_with_master_gtid.inc SELECT * FROM t1 ORDER BY a; diff --git a/mysql-test/suite/rpl/t/show_status_stop_slave_race-7126.test b/mysql-test/suite/rpl/t/show_status_stop_slave_race-7126.test index cd0f8aad106..ac4c9249c02 100644 --- a/mysql-test/suite/rpl/t/show_status_stop_slave_race-7126.test +++ b/mysql-test/suite/rpl/t/show_status_stop_slave_race-7126.test @@ -19,7 +19,7 @@ call mtr.add_suppression("Master is configured to log replication events"); # aborted by the master due to conflicting server_id from multiple connections. --let $rpl_allow_error= 1 --source include/wait_for_slave_to_stop.inc -start slave; +--source include/start_slave.inc --connection master --source include/rpl_end.inc diff --git a/sql-common/client.c b/sql-common/client.c index 94ae6eadc85..9b88855f1a5 100644 --- a/sql-common/client.c +++ b/sql-common/client.c @@ -1439,6 +1439,7 @@ mysql_init(MYSQL *mysql) bzero((char*) (mysql), sizeof(*(mysql))); mysql->options.connect_timeout= CONNECT_TIMEOUT; mysql->charset=default_client_charset_info; + mysql->options.use_ssl= 1; strmov(mysql->net.sqlstate, not_error_sqlstate); /* @@ -2100,9 +2101,9 @@ static int send_client_reply_packet(MCPVIO_EXT *mpvio, certificate, a ssl connection is required. If the server does not support ssl, we abort the connection. */ - if (mysql->options.use_ssl && - (mysql->options.extension && mysql->options.extension->tls_verify_server_cert) && - !(mysql->server_capabilities & CLIENT_SSL)) + if (mysql->options.use_ssl && !(mysql->server_capabilities & CLIENT_SSL) && + (!mysql->options.extension || + !mysql->options.extension->tls_allow_invalid_server_cert)) { set_mysql_extended_error(mysql, CR_SSL_CONNECTION_ERROR, unknown_sqlstate, ER(CR_SSL_CONNECTION_ERROR), @@ -2120,9 +2121,6 @@ static int send_client_reply_packet(MCPVIO_EXT *mpvio, enum enum_ssl_init_error ssl_init_error; const char *cert_error; unsigned long ssl_error; -#ifdef EMBEDDED_LIBRARY - DBUG_ASSERT(0); // embedded should not do SSL connect -#endif /* Send mysql->client_flag, max_packet_size - unencrypted otherwise @@ -2171,7 +2169,8 @@ static int send_client_reply_packet(MCPVIO_EXT *mpvio, DBUG_PRINT("info", ("IO layer change done!")); /* Verify server cert */ - if ((mysql->options.extension && mysql->options.extension->tls_verify_server_cert) && + if ((!mysql->options.extension || + !mysql->options.extension->tls_allow_invalid_server_cert) && ssl_verify_server_cert(mysql, &cert_error)) { set_mysql_extended_error(mysql, CR_SSL_CONNECTION_ERROR, unknown_sqlstate, @@ -2604,7 +2603,8 @@ int run_plugin_auth(MYSQL *mysql, char *data, uint data_len, /* Last attempt to validate the cert: compare cert info packet */ DBUG_ASSERT(mysql->options.use_ssl); DBUG_ASSERT(mysql->net.vio->ssl_arg); - DBUG_ASSERT(mysql->options.extension->tls_verify_server_cert); + DBUG_ASSERT(!mysql->options.extension || + !mysql->options.extension->tls_allow_invalid_server_cert); DBUG_ASSERT(!mysql->options.ssl_ca || !mysql->options.ssl_ca[0]); DBUG_ASSERT(!mysql->options.ssl_capath || !mysql->options.ssl_capath[0]); DBUG_ASSERT(auth_plugin->hash_password_bin); @@ -3849,7 +3849,7 @@ mysql_options(MYSQL *mysql,enum mysql_option option, const void *arg) sizeof(struct st_mysql_options_extention), MYF(MY_WME | MY_ZEROFILL)); if (mysql->options.extension) - mysql->options.extension->tls_verify_server_cert= *(my_bool*) arg; + mysql->options.extension->tls_allow_invalid_server_cert= !*(my_bool*) arg; break; case MYSQL_PLUGIN_DIR: EXTENSION_SET_STRING(&mysql->options, plugin_dir, arg); diff --git a/sql/rpl_mi.cc b/sql/rpl_mi.cc index c7741f7a1bc..f64f0fd1c93 100644 --- a/sql/rpl_mi.cc +++ b/sql/rpl_mi.cc @@ -31,7 +31,7 @@ static void init_master_log_pos(Master_info* mi); Master_info::Master_info(LEX_CSTRING *connection_name_arg, bool is_slave_recovery) :Slave_reporting_capability("I/O"), - ssl(0), ssl_verify_server_cert(0), fd(-1), io_thd(0), + ssl(1), ssl_verify_server_cert(1), fd(-1), io_thd(0), rli(is_slave_recovery), port(MYSQL_PORT), checksum_alg_before_fd(BINLOG_CHECKSUM_ALG_UNDEF), connect_retry(DEFAULT_CONNECT_RETRY), inited(0), abort_slave(0), diff --git a/storage/connect/myconn.cpp b/storage/connect/myconn.cpp index bb6f72de1f8..addcb0f6865 100644 --- a/storage/connect/myconn.cpp +++ b/storage/connect/myconn.cpp @@ -480,6 +480,7 @@ int MYSQLC::Open(PGLOBAL g, const char *host, const char *db, const char *pipe = NULL; //uint cto = 10, nrt = 20; my_bool my_true= 1; + my_bool my_false= 0; m_DB = mysql_init(NULL); @@ -528,8 +529,8 @@ int MYSQLC::Open(PGLOBAL g, const char *host, const char *db, mysql_options(m_DB, MYSQL_SET_CHARSET_NAME, csname); // Don't know what this one do but FEDERATED does it - mysql_options(m_DB, MYSQL_OPT_USE_THREAD_SPECIFIC_MEMORY, - (char*)&my_true); + mysql_options(m_DB, MYSQL_OPT_USE_THREAD_SPECIFIC_MEMORY, &my_true); + mysql_options(m_DB, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &my_false); if (!mysql_real_connect(m_DB, host, user, pwd, db, pt, pipe, CLIENT_MULTI_RESULTS | CLIENT_REMEMBER_OPTIONS)) { diff --git a/storage/federated/ha_federated.cc b/storage/federated/ha_federated.cc index db310b15955..7fc88ba0ab1 100644 --- a/storage/federated/ha_federated.cc +++ b/storage/federated/ha_federated.cc @@ -3140,6 +3140,7 @@ int ha_federated::real_connect() { char buffer[FEDERATED_QUERY_BUFFER_SIZE]; String sql_query(buffer, sizeof(buffer), &my_charset_bin); + my_bool my_false= 0; DBUG_ENTER("ha_federated::real_connect"); DBUG_ASSERT(mysql == NULL); @@ -3156,16 +3157,12 @@ int ha_federated::real_connect() of table */ /* this sets the csname like 'set names utf8' */ - mysql_options(mysql,MYSQL_SET_CHARSET_NAME, - this->table->s->table_charset->cs_name.str); + mysql_options(mysql,MYSQL_SET_CHARSET_NAME, table->s->table_charset->cs_name.str); + mysql_options(mysql, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &my_false); sql_query.length(0); - if (!mysql_real_connect(mysql, - share->hostname, - share->username, - share->password, - share->database, - share->port, + if (!mysql_real_connect(mysql, share->hostname, share->username, + share->password, share->database, share->port, share->socket, 0)) { stash_remote_error(); diff --git a/storage/federatedx/federatedx_io_mysql.cc b/storage/federatedx/federatedx_io_mysql.cc index fc32146b5cd..7512f8b16f0 100644 --- a/storage/federatedx/federatedx_io_mysql.cc +++ b/storage/federatedx/federatedx_io_mysql.cc @@ -429,6 +429,7 @@ int federatedx_io_mysql::actual_query(const char *buffer, size_t length) if (!mysql.net.vio) { my_bool my_true= 1; + my_bool my_false= 0; if (!(mysql_init(&mysql))) DBUG_RETURN(-1); @@ -440,15 +441,11 @@ int federatedx_io_mysql::actual_query(const char *buffer, size_t length) */ /* this sets the csname like 'set names utf8' */ mysql_options(&mysql, MYSQL_SET_CHARSET_NAME, get_charsetname()); - mysql_options(&mysql, MYSQL_OPT_USE_THREAD_SPECIFIC_MEMORY, - (char*) &my_true); + mysql_options(&mysql, MYSQL_OPT_USE_THREAD_SPECIFIC_MEMORY, &my_true); + mysql_options(&mysql, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &my_false); - if (!mysql_real_connect(&mysql, - get_hostname(), - get_username(), - get_password(), - get_database(), - get_port(), + if (!mysql_real_connect(&mysql, get_hostname(), get_username(), + get_password(), get_database(), get_port(), get_socket(), 0)) DBUG_RETURN(ER_CONNECT_TO_FOREIGN_DATA_SOURCE); mysql.reconnect= 1; diff --git a/storage/federatedx/ha_federatedx.cc b/storage/federatedx/ha_federatedx.cc index 3a62d33278a..e4c5bf8d13d 100644 --- a/storage/federatedx/ha_federatedx.cc +++ b/storage/federatedx/ha_federatedx.cc @@ -3655,6 +3655,7 @@ int ha_federatedx::discover_assisted(handlerton *hton, THD* thd, MYSQL_ROW rdata; ulong *rlen; my_bool my_true= 1; + my_bool my_false= 0; if (parse_url(thd->mem_root, &tmp_share, table_s, 1)) return HA_WRONG_CREATE_OPTION; @@ -3662,6 +3663,7 @@ int ha_federatedx::discover_assisted(handlerton *hton, THD* thd, mysql_init(&mysql); mysql_options(&mysql, MYSQL_SET_CHARSET_NAME, cs->cs_name.str); mysql_options(&mysql, MYSQL_OPT_USE_THREAD_SPECIFIC_MEMORY, (char*)&my_true); + mysql_options(&mysql, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &my_false); if (!mysql_real_connect(&mysql, tmp_share.hostname, tmp_share.username, tmp_share.password, tmp_share.database, diff --git a/storage/spider/mysql-test/spider/bg/t/slave_test_init.inc b/storage/spider/mysql-test/spider/bg/t/slave_test_init.inc index 739d88970c5..323c9669a73 100644 --- a/storage/spider/mysql-test/spider/bg/t/slave_test_init.inc +++ b/storage/spider/mysql-test/spider/bg/t/slave_test_init.inc @@ -16,7 +16,8 @@ if (!$SLAVE1_1_SLAVE_STATUS) MASTER_HOST = '127.0.0.1', MASTER_USER = 'root', MASTER_PASSWORD = '', - MASTER_PORT = $MASTER_1_MYPORT + MASTER_PORT = $MASTER_1_MYPORT, + MASTER_SSL_VERIFY_SERVER_CERT=0 ; } START SLAVE; diff --git a/storage/spider/mysql-test/spider/t/slave_test_init.inc b/storage/spider/mysql-test/spider/t/slave_test_init.inc index 739d88970c5..323c9669a73 100644 --- a/storage/spider/mysql-test/spider/t/slave_test_init.inc +++ b/storage/spider/mysql-test/spider/t/slave_test_init.inc @@ -16,7 +16,8 @@ if (!$SLAVE1_1_SLAVE_STATUS) MASTER_HOST = '127.0.0.1', MASTER_USER = 'root', MASTER_PASSWORD = '', - MASTER_PORT = $MASTER_1_MYPORT + MASTER_PORT = $MASTER_1_MYPORT, + MASTER_SSL_VERIFY_SERVER_CERT=0 ; } START SLAVE; diff --git a/storage/spider/spd_db_mysql.cc b/storage/spider/spd_db_mysql.cc index 1ffaaa9cce6..c156a0ededc 100644 --- a/storage/spider/spd_db_mysql.cc +++ b/storage/spider/spd_db_mysql.cc @@ -1906,12 +1906,10 @@ int spider_db_mbase::connect( mysql_options(db_conn, MYSQL_OPT_SSL_CA, conn->tgt_ssl_ca); mysql_options(db_conn, MYSQL_OPT_SSL_CAPATH, conn->tgt_ssl_capath); mysql_options(db_conn, MYSQL_OPT_SSL_CIPHER, conn->tgt_ssl_cipher); - if (conn->tgt_ssl_vsc) - { - my_bool verify_flg = TRUE; - mysql_options(db_conn, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, - &verify_flg); - } + } + { + my_bool verify_flg = conn->tgt_ssl_vsc != 0; + mysql_options(db_conn, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &verify_flg); } if (conn->tgt_default_file) diff --git a/unittest/embedded/test-connect.cc b/unittest/embedded/test-connect.cc index cd122286130..0ac128cc690 100644 --- a/unittest/embedded/test-connect.cc +++ b/unittest/embedded/test-connect.cc @@ -31,6 +31,8 @@ int main(int argc, char *argv[]) char *passwd; char *porta; unsigned int port; + int ret; + my_bool my_false= 0; if (get_evar(&host, &porta, &user, &passwd)) { @@ -60,19 +62,19 @@ int main(int argc, char *argv[]) return 1; } + mysql_options(mysql, MYSQL_OPT_SSL_VERIFY_SERVER_CERT, &my_false); + if (mysql_options(mysql, MYSQL_SET_CHARSET_NAME, "utf8mb4") != 0) { printf("mysql_options MYSQL_SET_CHARSET_NAME utf8mb4 failed: %s\n", mysql_error(mysql)); return 1; } - if (!mysql_real_connect(mysql, host, user, passwd, NULL, port, NULL, CLIENT_FOUND_ROWS | CLIENT_MULTI_RESULTS | CLIENT_REMEMBER_OPTIONS)) { + if ((ret= !mysql_real_connect(mysql, host, user, passwd, NULL, port, NULL, + CLIENT_FOUND_ROWS | CLIENT_MULTI_RESULTS | CLIENT_REMEMBER_OPTIONS))) printf("mysql_real_connect failed: %s\n", mysql_error(mysql)); - return 1; - } mysql_close(mysql); mysql_thread_end(); mysql_library_end(); - return 0; - + return ret; }