pt-online-schema-change should error if server is a slave in row based replication

Description

See

That issue is supposed to be fixed in 2.2.19. However, using version 3.5.7 and running pt-osc on replica with binlog_format=ROW the tool executes just fine, instead of giving an error like linked issue says it would.

This can lead to source/replica becoming inconsistent if there are writes on source when the tool runs on replica.

Previous issue mentions --force-slave-run option, which I’m not finding in the documentation. I’m also not finding any code that would check for that option.

How to repeat:

  • Set up source/replica, make sure binlog_format=ROW.

  • Create table on source

  • run pt-osc on replica, for example pt-online-schema-change --alter="engine=innodb" --execute D=test,t=mytest

It should error out according to PT-1149, but doesn’t.

Environment

None

AFFECTED CS IDs

CS0043180

Activity

Show:

Details

Assignee

Reporter

Priority

Components

Affects versions

Fix versions

Needs QA

Yes

Smart Checklist

Created January 13, 2024 at 12:45 PM
Updated November 15, 2024 at 1:30 PM