Skip to main content

pt-table-sync


Usage

Print Diff SQL

pt-table-sync \
  --print \
  --chunk-size=1000 \
  h=master_host,P=3306,u=root,p=123456,D=mydb,t=mytable \
  h=slave_host,P=3306,u=root,p=123456

Execute Diff

pt-table-sync \
  --execute \
  --chunk-size=1000 \
  h=master_host,P=3306,u=root,p=123456,D=mydb,t=mytable \
  h=slave_host,P=3306,u=root,p=123456