mirror of
https://github.com/MariaDB/server.git
synced 2025-01-22 06:44:16 +01:00
merge mysql-5.1-rep+3 --> mysql-5.1-rep+2-delivery1
This commit is contained in:
commit
93726f51c1
3 changed files with 19 additions and 2 deletions
|
@ -13,6 +13,10 @@
|
||||||
# timezone used in CONVERT_TZ is not binlogged. To debug (by Guilhem
|
# timezone used in CONVERT_TZ is not binlogged. To debug (by Guilhem
|
||||||
# and possibly Konstantin).
|
# and possibly Konstantin).
|
||||||
|
|
||||||
|
--disable_query_log
|
||||||
|
CALL mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT");
|
||||||
|
--enable_query_log
|
||||||
|
|
||||||
--disable_ps_protocol
|
--disable_ps_protocol
|
||||||
|
|
||||||
source include/master-slave.inc;
|
source include/master-slave.inc;
|
||||||
|
|
|
@ -183,11 +183,18 @@ int register_slave(THD* thd, uchar* packet, uint packet_length)
|
||||||
get_object(p,si->host, "Failed to register slave: too long 'report-host'");
|
get_object(p,si->host, "Failed to register slave: too long 'report-host'");
|
||||||
get_object(p,si->user, "Failed to register slave: too long 'report-user'");
|
get_object(p,si->user, "Failed to register slave: too long 'report-user'");
|
||||||
get_object(p,si->password, "Failed to register slave; too long 'report-password'");
|
get_object(p,si->password, "Failed to register slave; too long 'report-password'");
|
||||||
/*6 is the total length of port and master_id*/
|
if (p+10 > p_end)
|
||||||
if (p+6 != p_end)
|
|
||||||
goto err;
|
goto err;
|
||||||
si->port= uint2korr(p);
|
si->port= uint2korr(p);
|
||||||
p += 2;
|
p += 2;
|
||||||
|
/*
|
||||||
|
We need to by pass the bytes used in the fake rpl_recovery_rank
|
||||||
|
variable. It was removed in patch for BUG#13963. But this would
|
||||||
|
make a server with that patch unable to connect to an old master.
|
||||||
|
See: BUG#49259
|
||||||
|
*/
|
||||||
|
// si->rpl_recovery_rank= uint4korr(p);
|
||||||
|
p += 4;
|
||||||
if (!(si->master_id= uint4korr(p)))
|
if (!(si->master_id= uint4korr(p)))
|
||||||
si->master_id= server_id;
|
si->master_id= server_id;
|
||||||
si->thd= thd;
|
si->thd= thd;
|
||||||
|
|
|
@ -1612,6 +1612,12 @@ int register_slave_on_master(MYSQL* mysql, Master_info *mi,
|
||||||
pos= net_store_data(pos, (uchar*) report_user, report_user_len);
|
pos= net_store_data(pos, (uchar*) report_user, report_user_len);
|
||||||
pos= net_store_data(pos, (uchar*) report_password, report_password_len);
|
pos= net_store_data(pos, (uchar*) report_password, report_password_len);
|
||||||
int2store(pos, (uint16) report_port); pos+= 2;
|
int2store(pos, (uint16) report_port); pos+= 2;
|
||||||
|
/*
|
||||||
|
Fake rpl_recovery_rank, which was removed in BUG#13963,
|
||||||
|
so that this server can register itself on old servers,
|
||||||
|
see BUG#49259.
|
||||||
|
*/
|
||||||
|
int4store(pos, /* rpl_recovery_rank */ 0); pos+= 4;
|
||||||
/* The master will fill in master_id */
|
/* The master will fill in master_id */
|
||||||
int4store(pos, 0); pos+= 4;
|
int4store(pos, 0); pos+= 4;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue