@@ -114,7 +114,6 @@ static my_bool verbose= 0, opt_no_create_info= 0, opt_no_data= 0,
114
114
opt_slave_apply = 0 ,
115
115
opt_include_master_host_port = 0 ,
116
116
opt_events = 0 , opt_comments_used = 0 ,
117
- opt_galera_sst_mode = 0 ,
118
117
opt_alltspcs = 0 , opt_notspcs = 0 ;
119
118
static my_bool insert_pat_inited = 0 , debug_info_flag = 0 , debug_check_flag = 0 ;
120
119
static ulong opt_max_allowed_packet , opt_net_buffer_length ;
@@ -351,14 +350,6 @@ static struct my_option my_long_options[] =
351
350
{"force" , 'f' , "Continue even if we get an SQL error." ,
352
351
& ignore_errors , & ignore_errors , 0 , GET_BOOL , NO_ARG ,
353
352
0 , 0 , 0 , 0 , 0 , 0 },
354
- {"galera-sst-mode" , OPT_GALERA_SST_MODE ,
355
- "This mode should normally be used in mysqldump snapshot state transfer "
356
- "(SST) in a Galera cluster. If enabled, mysqldump additionally dumps "
357
- "commands to turn off binary logging and SET global gtid_binlog_state "
358
- "with the current value. Note: RESET MASTER needs to be executed on the "
359
- "server receiving the resulting dump." ,
360
- & opt_galera_sst_mode , & opt_galera_sst_mode , 0 , GET_BOOL , NO_ARG , 0 , 0 , 0 ,
361
- 0 , 0 , 0 },
362
353
{"gtid" , OPT_USE_GTID , "Used together with --master-data=1 or --dump-slave=1."
363
354
"When enabled, the output from those options will set the GTID position "
364
355
"instead of the binlog file and offset; the file/offset will appear only as "
@@ -4903,43 +4894,6 @@ static int dump_selected_tables(char *db, char **table_names, int tables)
4903
4894
} /* dump_selected_tables */
4904
4895
4905
4896
4906
- /**
4907
- Add the following statements to the generated dump:
4908
- a) SET @@session.sql_log_bin=OFF;
4909
- b) SET @@global.gtid_binlog_state='[N-N-N,...]'
4910
- */
4911
- static int wsrep_set_sst_cmds (MYSQL * mysql ) {
4912
- MYSQL_RES * res ;
4913
- MYSQL_ROW row ;
4914
-
4915
- if (mysql_get_server_version (mysql ) < 100005 ) {
4916
- /* @@gtid_binlog_state does not exist. */
4917
- return 0 ;
4918
- }
4919
-
4920
- if (mysql_query_with_error_report (mysql , & res , "SELECT "
4921
- "@@global.gtid_binlog_state" ))
4922
- return 1 ;
4923
-
4924
- if (mysql_num_rows (res ) != 1 )
4925
- /* No entry for @@global.gtid_binlog_state, nothing needs to be done. */
4926
- return 0 ;
4927
-
4928
- if (!(row = mysql_fetch_row (res )) || !(char * )row [0 ])
4929
- return 1 ;
4930
-
4931
- /* first, add a command to turn off binary logging, */
4932
- fprintf (md_result_file , "SET @@session.sql_log_bin=OFF;\n" );
4933
-
4934
- /* followed by, a command to set global gtid_binlog_state. */
4935
- fprintf (md_result_file , "SET @@global.gtid_binlog_state='%s';\n" ,
4936
- (char * )row [0 ]);
4937
-
4938
- mysql_free_result (res );
4939
- return 0 ;
4940
- }
4941
-
4942
-
4943
4897
static int do_show_master_status (MYSQL * mysql_con , int consistent_binlog_pos ,
4944
4898
int have_mariadb_gtid , int use_gtid )
4945
4899
{
@@ -5936,9 +5890,6 @@ int main(int argc, char **argv)
5936
5890
if (opt_slave_apply && add_stop_slave ())
5937
5891
goto err ;
5938
5892
5939
- if (opt_galera_sst_mode && wsrep_set_sst_cmds (mysql ))
5940
- goto err ;
5941
-
5942
5893
if (opt_master_data && do_show_master_status (mysql , consistent_binlog_pos ,
5943
5894
have_mariadb_gtid , opt_use_gtid ))
5944
5895
goto err ;
0 commit comments