gtid-errant-fixer

command module
v1.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2021 License: MIT Imports: 6 Imported by: 0

README

gtid-errant-fixer

simple cli tool to fix errant gtid for MySQL Multi Source Replication(MSR)

If you don't use MSR, and use orchestrator (>=3.0.14), it's OK to fix on it. Please see also the detail on the Percona Live slide

usage

$ ./gtid-errant-fixer --help
Usage of ./gtid-errant-fixer:
  -c string
        mysql client config(need SUPER priv to operate stop / slave) (default ".my.cnf")
  -f    force execution (skip prompt to confirm Y/N
  -p string
        mysql client config (need REPLICATION SLAVE)
  -u string
        mysql client config (need REPLICATION SLAVE)

example

you can reset errant_gtid which you can confirm with server_id and host (report_host is required to enable)

$ ./gtid-errant-fixer
errant transaction pre-check:
 errant_gtid ea2c5164-930b-11eb-901c-0242c0a81004:1: server_id: 3, host mysql3
stopping replica
original gtid_executed:
e9f7ad21-930b-11eb-8646-0242c0a81002:1-18,
ea052114-930b-11eb-8dd3-0242c0a81003:1-18,
ea2c5164-930b-11eb-901c-0242c0a81004:1
would you continue to reset? (y/n) [n]: y
RESET SLAVE
RESET MASTER
SET GLOBAL gtid_purged='e9f7ad21-930b-11eb-8646-0242c0a81002:1-18,ea052114-930b-11eb-8dd3-0242c0a81003:1-18'
resuming replica
completed.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
src

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL