github / github/gh-ost

ERROR Error 1146: Table 'Test._Test_gho' doesn't exist; query=

Open
#683 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
13.6k
Forks
1.4k
Avg merge
2h 31m
Merged PRs (30d)
4

Description

my gh-ost version is 1.0.47.

From the log could see that
2018-11-23 06:46:10 INFO Issuing and expecting this to block: rename /* gh-ost */ table `Test`.`Test` to `Test`.`_Test_del`, `Test`.`_Test_gho` to `Test`.`Test`
Test table is rename ot _test_del
and
_test_gho is renamed to Test.

Later we could see it is looking for 'Test._Test_gho'
2018-11-23 06:47:24 ERROR Error 1146: Table 'Test._Test_gho' doesn't exist; query=
replace /* gh-ost `Test`.`_Test_gho` */ into
`Test`.`_Test_gho`

Could you explain why this error exists? and why gh-ost is looking for 'Test._Test_gho' table?

Is this data migration completed or still something missing, which are not completed.
I could verify a few data and it looks like the data is migrated with the schema change.

Below lines are extracted from error log file

2018-11-23 06:42:57 INFO rotate to next log from mysql-bin-changelog.195443:0 to mysql-bin-changelog.195443
2018/11/23 06:44:34 binlogsyncer.go:573: [info] rotate to (mysql-bin-changelog.195444, 4)
2018/11/23 06:44:34 binlogsyncer.go:573: [info] rotate to (mysql-bin-changelog.195444, 4)
2018-11-23 06:44:34 INFO rotate to next log from mysql-bin-changelog.195444:140451866 to mysql-bin-changelog.195444
2018-11-23 06:44:34 INFO rotate to next log from mysql-bin-changelog.195444:0 to mysql-bin-changelog.195444
2018-11-23 06:46:09 INFO Row copy complete
2018-11-23 06:46:09 INFO Grabbing voluntary lock: gh-ost.3307925.lock
2018-11-23 06:46:09 INFO Setting LOCK timeout as 6 seconds
2018-11-23 06:46:09 INFO Looking for magic cut-over table
2018-11-23 06:46:09 INFO Creating magic cut-over table `Test`.`_Test_del`
2018-11-23 06:46:09 INFO Magic cut-over table created
2018-11-23 06:46:09 INFO Locking `Test`.`Test`, `Test`.`_Test_del`
2018-11-23 06:46:09 INFO Tables locked
2018-11-23 06:46:09 INFO Session locking original & magic tables is 3307925
2018-11-23 06:46:09 INFO Writing changelog state: AllEventsUpToLockProcessed:1542955569917032966
2018-11-23 06:46:09 INFO Waiting for events up to lock
2018-11-23 06:46:10 INFO Intercepted changelog state AllEventsUpToLockProcessed
2018-11-23 06:46:10 INFO Handled changelog state AllEventsUpToLockProcessed
2018-11-23 06:46:10 INFO Waiting for events up to lock: got AllEventsUpToLockProcessed:1542955569917032966
2018-11-23 06:46:10 INFO Done waiting for events up to lock; duration=909.505441ms
2018-11-23 06:46:10 INFO Setting RENAME timeout as 3 seconds
2018-11-23 06:46:10 INFO Session renaming tables is 3307932
2018-11-23 06:46:10 INFO Issuing and expecting this to block: rename /* gh-ost */ table `Test`.`Test` to `Test`.`_Test_del`, `Test`.`_Test_gho` to `Test`.`Test`
2018-11-23 06:46:11 INFO Found atomic RENAME to be blocking, as expected. Double checking the lock is still in place (though I don't strictly have to)
2018-11-23 06:46:11 INFO Checking session lock: gh-ost.3307925.lock
2018-11-23 06:46:11 INFO Connection holding lock on original table still exists
2018-11-23 06:46:11 INFO Will now proceed to drop magic table and unlock tables
2018-11-23 06:46:11 INFO Dropping magic cut-over table
2018-11-23 06:46:11 INFO Releasing lock from `Test`.`Test`, `Test`.`_Test_del`
2018-11-23 06:46:11 INFO Tables unlocked
2018-11-23 06:46:12 INFO Tables renamed
2018-11-23 06:46:12 INFO Lock & rename duration: 2.338575098s. During this time, queries on `Test` were blocked
2018-11-23 06:46:12 INFO Looking for magic cut-over table
2018/11/23 06:46:28 binlogsyncer.go:573: [info] rotate to (mysql-bin-changelog.195445, 4)
2018/11/23 06:46:28 binlogsyncer.go:573: [info] rotate to (mysql-bin-changelog.195445, 4)
2018-11-23 06:46:28 INFO rotate to next log from mysql-bin-changelog.195445:134218044 to mysql-bin-changelog.195445
2018-11-23 06:46:28 INFO rotate to next log from mysql-bin-changelog.195445:0 to mysql-bin-changelog.195445
2018-11-23 06:47:24 ERROR Error 1146: Table 'Test._Test_gho' doesn't exist; query=
replace /* gh-ost `Test`.`_Test_gho` */ into
`Test`.`_Test_gho`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.