[MDEV-10553] Semi-sync replication hangs when master opens new binlog file Created: 2016-08-13  Updated: 2016-08-16  Resolved: 2016-08-16

Status: Closed
Project: MariaDB Server
Component/s: Replication
Affects Version/s: 10.1.14
Fix Version/s: 10.1.17

Type: Bug Priority: Major
Reporter: Joseph Glanville Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: None
Environment:

Ubuntu 14.04



 Description   

Hi,

I am having an issue with MariaDB semi-sync replication.
Setting up replication between master and slaves works as expected but when the master begins writing to a new binlog file replication stalls on waiting for an ack from the semi-sync slave.
I have the fallback to async set very high because I basically don't want the server to ever commit writes to the master that aren't committed to the slave.

I have discussed this somewhat on the mailing list and have created this gist which reliably reproduces the issue: https://gist.github.com/josephglanville/c9a69b02de319ee06aef1a8d787bcce3

It's possible this is a configuration issue rather than a bug, config for master and slave is generated in the scripts in the gist so if that is the case hopefully it's an easy fix.

Joseph.



 Comments   
Comment by Joseph Glanville [ 2016-08-13 ]

Switching to AFTER_COMMIT works around the problem but doesn't accomplish loss-less replication.
Discussion on the mailing list indicates this is likely a race updating MYSQL_BIN_LOG::log_file_name as the after_sync callback is called with the new file name but the last offset of the previous binlog file.

Comment by Kristian Nielsen [ 2016-08-16 ]

https://lists.launchpad.net/maria-discuss/msg03788.html
https://lists.launchpad.net/maria-discuss/msg03793.html

Comment by Kristian Nielsen [ 2016-08-16 ]

Pushed to 10.1:

http://lists.askmonty.org/pipermail/commits/2016-August/009641.html

Generated at Thu Feb 08 07:43:06 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.