Skip to content

FATAL No shared unique key can be found after ALTER! Bailing out #647

@linuxybird

Description

@linuxybird

statement:ALTER TABLE _100 DROP PRIMARY KEY, ADD UNIQUE KEY uidx_mobile_userid(id,a);

2018-10-09 12:02:39 INFO starting gh-ost 1.0.46
2018-10-09 12:02:39 INFO Migrating test._100
2018-10-09 12:02:39 INFO connection validated on 10.17.4.23:3307
2018-10-09 12:02:39 INFO User has ALL privileges
2018-10-09 12:02:39 INFO binary logs validated on 10.17.4.23:3307
2018-10-09 12:02:39 INFO Restarting replication on 10.17.4.23:3307 to make sure binlog settings apply to replication thread
2018-10-09 12:02:39 INFO Inspector initiated on DEV_10_17_4_23:3307, version 5.5.19-log
2018-10-09 12:02:39 INFO Table found. Engine=InnoDB
2018-10-09 12:02:39 WARNING --skip-foreign-key-checks provided: will not check for foreign keys
2018-10-09 12:02:39 INFO Estimated number of rows via EXPLAIN: 2
2018-10-09 12:02:39 INFO Recursively searching for replication master
2018-10-09 12:02:39 INFO Master found to be DEV_10_17_4_23:3307
2018-10-09 12:02:39 INFO log_slave_updates validated on 10.17.4.23:3307
2018-10-09 12:02:39 INFO connection validated on 10.17.4.23:3307
2018/10/09 12:02:39 binlogsyncer.go:79: ^[[0;37m[info] create BinlogSyncer with config {99999 mysql 10.17.4.23 3307 ghost false false }^[[0m
2018-10-09 12:02:39 INFO Connecting binlog streamer at binlog.000004:85784
2018/10/09 12:02:39 binlogsyncer.go:246: ^[[0;37m[info] begin to sync binlog from position (binlog.000004, 85784)^[[0m
2018/10/09 12:02:39 binlogsyncer.go:139: ^[[0;37m[info] register slave for master server 10.17.4.23:3307^[[0m
2018/10/09 12:02:39 binlogsyncer.go:573: ^[[0;37m[info] rotate to (binlog.000004, 85784)^[[0m
2018-10-09 12:02:39 INFO rotate to next log name: binlog.000004
2018-10-09 12:02:39 INFO connection validated on 10.17.4.23:3307
2018-10-09 12:02:39 INFO connection validated on 10.17.4.23:3307
2018-10-09 12:02:39 INFO will use time_zone='SYSTEM' on applier
2018-10-09 12:02:39 INFO Examining table structure on applier
2018-10-09 12:02:39 INFO Applier initiated on DEV_10_17_4_23:3307, version 5.5.19-log
2018-10-09 12:02:39 INFO Dropping table test.__100_gho
2018-10-09 12:02:39 INFO Table dropped
2018-10-09 12:02:39 INFO Dropping table test.__100_del
2018-10-09 12:02:39 INFO Table dropped
2018-10-09 12:02:39 INFO Dropping table test.__100_ghc
2018-10-09 12:02:39 INFO Table dropped
2018-10-09 12:02:39 INFO Creating changelog table test.__100_ghc
2018-10-09 12:02:39 INFO Changelog table created
2018-10-09 12:02:39 INFO Creating ghost table test.__100_gho
2018-10-09 12:02:39 INFO Ghost table created
2018-10-09 12:02:39 INFO Altering ghost table test.__100_gho
2018-10-09 12:02:40 INFO Ghost table altered
2018-10-09 12:02:40 INFO Intercepted changelog state GhostTableMigrated
2018-10-09 12:02:40 INFO Waiting for ghost table to be migrated. Current lag is 0s
2018-10-09 12:02:40 INFO Handled changelog state GhostTableMigrated
2018-10-09 12:02:40 INFO Tearing down inspector
2018-10-09 12:02:40 INFO Tearing down applier
2018-10-09 12:02:40 INFO Tearing down streamer
2018-10-09 12:02:40 FATAL No shared unique key can be found after ALTER! Bailing out

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions