[MXS-1678] Stopping IO thread on relay master causes it to be promoted as master Created: 2018-02-21  Updated: 2018-03-12  Resolved: 2018-03-01

Status: Closed
Project: MariaDB MaxScale
Component/s: mariadbmon
Affects Version/s: 2.1.13
Fix Version/s: 2.1.14

Type: Bug Priority: Major
Reporter: markus makela Assignee: markus makela
Resolution: Fixed Votes: 0
Labels: None


 Description   

With a four server setup consisting of two master-slave pairs, A→B and C→D where A and C are masters, configuring C to replicate from A will form a multi-tiered replication topology (i.e. C will be a relay master).

"Before stopping IO thread"

Servers.
-------------------+-----------------+-------+-------------+--------------------
Server             | Address         | Port  | Connections | Status
-------------------+-----------------+-------+-------------+--------------------
server1            | 127.0.0.1       |  3000 |           0 | Master, Running
server2            | 127.0.0.1       |  3001 |           0 | Slave, Running
server3            | 127.0.0.1       |  3002 |           0 | Relay Master, Slave, Running
server4            | 127.0.0.1       |  3003 |           0 | Slave, Running
-------------------+-----------------+-------+-------------+--------------------

When the IO thread on C (server3) is stopped, it will be "promoted" as a master server.

"After stopping IO thread"

Servers.
-------------------+-----------------+-------+-------------+--------------------
Server             | Address         | Port  | Connections | Status
-------------------+-----------------+-------+-------------+--------------------
server1            | 127.0.0.1       |  3000 |           0 | Master, Running
server2            | 127.0.0.1       |  3001 |           0 | Slave, Running
server3            | 127.0.0.1       |  3002 |           0 | Master, Running
server4            | 127.0.0.1       |  3003 |           0 | Slave, Running
-------------------+-----------------+-------+-------------+--------------------

If C disconnects from A, it should not be treated as a master server.



 Comments   
Comment by markus makela [ 2018-03-01 ]

The master_id was not stored if the IO thread was stopped.

Generated at Thu Feb 08 04:08:36 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.