Percona fails to properly stop replication thread if super_read_only=1, autocommit=0 and >=5.6.29

Bug #1587114 reported by Arturas Moskvinas
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.6
Triaged
Medium
Unassigned
5.7
Triaged
Medium
Unassigned

Bug Description

Percona 5.6.29-76.2-1 fails to properly stop replication if super_read_only mode is on and session is in autocommit=0 mode. Actually it is stopping thread but also returns error:
```
ERROR 1290 (HY000): The MySQL server is running with the --read-only (super) option so it cannot execute this statement
```

How to reproduce:
1. Setup slave replication
2. Execute `echo 'set global super_read_only=1; set autocommit=0; stop slave sql_thread' | mysql`

Result:
```
ERROR 1290 (HY000) at line 1: The MySQL server is running with the --read-only (super) option so it cannot execute this statement
```
And SQL_THREAD is actually - stopped.

Expect:
No error+stop thread or previous error and sql_thread still running...

tags: added: super-read-only
Revision history for this message
Arturas Moskvinas (arturas-w) wrote :

Some essential settings we use:
```
relay_log_info_repository = TABLE
default-storage-engine = innodb
```

Revision history for this message
Arturas Moskvinas (arturas-w) wrote :

Not only `stop slave` is affected, you cannot `change master` also when autocommit=0

Changed in percona-server:
assignee: nobody → Jericho Rivera (jericho-rivera)
Revision history for this message
Jericho Rivera (jericho-rivera) wrote :

This is easily reproducible on latest PS 5.6 and 5.7, confirmed that I had to add relay-log-info-repository=TABLE and master-info-repository=TABLE to reproduce.

slave1 [localhost] {root} ((none)) > set global super_read_only=1; set autocommit=0; stop slave sql_thread;
Query OK, 0 rows affected (0.00 sec)

Query OK, 0 rows affected (0.00 sec)

ERROR 1290 (HY000): The MySQL server is running with the --super-read-only option so it cannot execute this statement

Revision history for this message
Jericho Rivera (jericho-rivera) wrote :

@Arturas, were you able to test if this affects upstream MySQL as well?

Revision history for this message
Arturas Moskvinas (arturas-w) wrote :

Upstream MySQL 5.6 is not supporting `super_read_only` option, it is only available in 5.7, we do not have any production databases running 5.7 at the moment.

Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-1716

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.