Bug #80010 Error: 1871 when promoting an instance on H/A group (mysql 5.7.x)
Submitted: 15 Jan 2016 19:27 Modified: 28 Jan 2016 2:47
Reporter: Miguel Araujo Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Fabric: High Availability Severity:S3 (Non-critical)
Version:1.6.3 OS:Any
Assigned to: Nelson Goncalves CPU Architecture:Any

[15 Jan 2016 19:27] Miguel Araujo
Description:
Promoting an instance to master on an H/A group leads to the following error on the mysqld instance:

[ERROR] Slave I/O for channel '': Slave failed to initialize master info structure from the repository, Error_code: 1871

https://dev.mysql.com/doc/refman/5.6/en/error-messages-server.html#error_er_slave_mi_init_...

Only happens for MySQL >= 5.7

How to repeat:
1) Create H/A group: group create test
2) Add at least 3 mysqld instances to the group: group add test HOST:PORT , ...
3) Promote one mysqld instance to master: group promote test --slave_id=HOST:PORT

On the promoted instance (master) the error log shows:

[ERROR] Slave I/O for channel '': Slave failed to initialize master info structure from the repository, Error_code: 1871
[15 Jan 2016 19:41] Miguel Araujo
Tested with MySQL 5.7.10 and 5.7.11
[26 Jan 2016 11:08] Nelson Goncalves
Posted by developer:
 
Issue fixed by patch for BUG#21932765 - SLAVE PROMOTION DOES NOT CONSIDER WEIGHT, DOES NOT GUARANTEE LATEST SLAVE
in release 1.5.7 and 1.6.3. 
This issue happened because of slave specific commands being executed on a server that was not configured as as slave.
The failover/promote algorithm was enhanced in the patch for BUG#21932765 as a result fixes this issue.
[28 Jan 2016 2:47] Philip Olson
Fixed as of the upcoming MySQL Fabric 1.5.7 / 1.6.3 releases, and here's the changelog entry:

The failover and promotion algorithm was improved, which fixes an issue
where promoting a slave to a master could result in slave specific
commands being executed on a host not configured as a slave, which
resulted in errors.

Thank you for the bug report.