Details
-
Bug
-
Status: Approved (View Workflow)
-
Critical
-
Resolution: Unresolved
-
11.4
-
None
-
None
Description
DESCRIPTION
===========
To fix in 11.4. Complements MDEV-42004.
Repl_semi_sync_slave::kill_connection() (sql/semisync_slave.cc) is called from
Repl_semi_sync_slave::slave_stop() at the slave IO thread exit
(handle_slave_io(), sql/slave.cc). It connects to the master again with a new
handle to send "KILL <thread_id>" for the IO thread's connection.
When the connection is already closed there is nothing to kill: end_server()
has deleted the vio (mysql->net.vio == NULL) after a failed or interrupted
(re)connect, e.g. STOP SLAVE interrupting a reconnect to a master that accepts
the connection but does not answer (MDEV-42004). mysql->thread_id is a stale
one by then. The new connect to the same unresponsive master waits
rpl_semi_sync_slave_kill_conn_timeout once more, and its failure path is a
no-op.
Fix: return early from kill_connection() when mysql->net.vio is NULL.
Attachments
Issue Links
- causes
-
MDEV-39583 Replace the slave-side graceful self-KILL with the master-side COM_QUIT handing in Semi-Synchronous Replication
-
- Stalled
-
- split from
-
MDEV-42004 STOP SLAVE stalls for several seconds on a slave whose master is unreachable
-
- Closed
-