pt-online-schema-change wrongly thinks columns are trying to be renamed

Bug #1592072 reported by tekess
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Percona Toolkit moved to https://jira.percona.com/projects/PT
Fix Released
Medium
Carlos Salguero

Bug Description

When the word 'change' appears in a COMMENT string, pt-online-schema-change thinks you're trying to rename columns, even if you're not.

$ pt-online-schema-change -h localhost -u tests --ask-pass --execute --force --alter-foreign-keys-method none --alter "ADD COLUMN foobar VARCHAR(10) COMMENT 'change plus more than one word';" D=foo,t=bar
Enter MySQL password:
No slaves found. See --recursion-method if host tbox-0-0-smeruelo-e19b has slaves.
Not checking slave lag because no slaves were found and --check-slave-lag was not specified.
Operation, tries, wait:
  analyze_table, 10, 1
  copy_rows, 10, 0.25
  create_triggers, 10, 1
  drop_triggers, 10, 1
  swap_tables, 10, 1
  update_foreign_keys, 10, 1
Not updating foreign keys because --alter-foreign-keys-method=none. Foreign keys that reference the table will no longer work.
Altering `foo`.`bar`...
--alter appears to rename these columns:
  plus to more
The tool should handle this correctly, but you should test it first because if it fails the renamed columns' data will be lost! Specify --no-check-alter to disable this check and perform the --alter.
`foo`.`bar` was not altered.
--check-alter failed.

$ pt-online-schema-change --version
pt-online-schema-change 2.2.17

# mysqld --version
mysqld Ver 5.5.36-34.2-4 for debian-linux-gnu on x86_64 ((Debian))

$ cat /etc/debian_version
6.0.8

$ uname -a
Linux rubik 2.6.32-5-amd64 #1 SMP Mon Sep 23 22:14:43 UTC 2013 x86_64 GNU/Linux

Revision history for this message
Sveta Smirnova (svetasmirnova) wrote :

Thank you for the report.

Verified as described with versions 2.2.20 and 3.0.2

tags: added: pt-online-schema-change
Changed in percona-toolkit:
status: New → Confirmed
tags: added: pt126
Revision history for this message
Carlos Salguero (carlos-salguero) wrote :
Changed in percona-toolkit:
status: Confirmed → Fix Committed
assignee: nobody → Carlos Salguero (carlos-salguero)
importance: Undecided → Medium
milestone: none → 3.0.3
Changed in percona-toolkit:
status: Fix Committed → Fix Released
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/PT-707

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.