ERROR Error 1146: Table '<db>._temp_no_ghc' doesn't exist

未关闭
#1,432 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 10 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
25/100
Issue 类型
缺陷
描述清晰度
需要澄清
活跃度
停滞
技术栈
go, mysql
领域
database

调研方向

首先,针对报告的 Azure/MySQL 设置重现该命令,并检查 binlogsyncer.go 中与缺失的 _temp_no_ghc 表相关的关闭消息。确定为什么该表不存在时迁移仍报告已完成;完成意味着记录原因,并确认该命令不再产生 Error 1146。

由索引模型根据 Issue 内容生成。

描述

I am using this command:

./gh-ost --azure=true --host="host" --database="db-name" --user="user" --password="password" --ssl-ca=DigiCertGlobalRootG2.crt.pem --ssl=true --ssl-allow-insecure=true --assume-rbr --allow-on-master=true --alter="ALTER TABLE temp_no ADD COLUMN tempID int NULL DEFAULT NULL"

Error:

[2024/07/09 17:19:44] [info] binlogsyncer.go:374 begin to sync binlog from position (mysql-bin.000112, 77638393)
[2024/07/09 17:19:44] [info] binlogsyncer.go:791 rotate to (mysql-bin.000112, 77638393)
# Migrating `<db>`.`temp_no`; Ghost table is `<db>`.`_temp_no_gho`
# Migration started at Tue Jul 09 17:19:43 -0400 2024
# chunk-size: 1000; max-lag-millis: 1500ms; dml-batch-size: 10; max-load: ; critical-load: ; nice-ratio: 0.000000
# throttle-additional-flag-file: /tmp/gh-ost.throttle 
# Serving on unix socket: /tmp/gh-ost.<db>.temp_no.sock
Copy: 0/0 100.0%; Applied: 0; Backlog: 0/1000; Time: 1s(total), 0s(copy); streamer: mysql-bin.000112:77643330; Lag: 0.12s, HeartbeatLag: 0.02s, State: migrating; ETA: due
Copy: 0/150 0.0%; Applied: 0; Backlog: 0/1000; Time: 1s(total), 0s(copy); streamer: mysql-bin.000112:77643330; Lag: 0.12s, HeartbeatLag: 0.02s, State: migrating; ETA: N/A
CREATE TABLE `_temp_no_gho` (
  `id` int NOT NULL AUTO_INCREMENT,
  `no` varchar(10) DEFAULT NULL,
  `status` varchar(25) NOT NULL,
  `tempID` int DEFAULT NULL,
  PRIMARY KEY (`id`)
) /*!50100 TABLESPACE `innodb_system` */ ENGINE=InnoDB AUTO_INCREMENT=230 DEFAULT CHARSET=utf8mb3
[2024/07/09 17:19:45] [info] binlogsyncer.go:180 syncer is closing...
[2024/07/09 17:19:45] [info] binlogsyncer.go:864 kill last connection id 2090439
[2024/07/09 17:19:45] [info] binlogsyncer.go:210 syncer is closed
2024-07-09 17:19:45 ERROR Error 1146: Table '<db>._temp_no_ghc' doesn't exist
# Done
主要语言
Go
星标
13.6k
派生
1.4k
平均合并
9 天 19 小时
30 天内合并 PR
1

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

github/gh-ost 的其他 Issue

查看 github/gh-ost 的全部 Issue

相似的 Issue

更多 Go Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。