Add IF EXISTS to create table and databases queries in pt-table-checksum

Bug #950290 reported by Alfie John
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Toolkit moved to https://jira.percona.com/projects/PT
Invalid
Medium
Unassigned

Bug Description

pt-table-checksum does the following if the schema isn't on the master:

  - CREATE DATABASE percona
  - CREATE TABLE dsns
  - CREATE TABLE checksums

However if a slave already has the schema, replication breaks with database/table "already exists".

Revision history for this message
Daniel Nichter (daniel-nichter) wrote :

Confirmed. In create_repl_table() for example:

   $sql =~ s/CREATE TABLE checksums/CREATE TABLE $repl_table/;

tags: added: breaks-replication pt-table-checksum
Changed in percona-toolkit:
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Daniel Nichter (daniel-nichter) wrote :

This is a duplicate of bug 950294, just the other side of the problem.

Changed in percona-toolkit:
status: Confirmed → Invalid
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.