Skip to content
This repository has been archived by the owner on Nov 24, 2023. It is now read-only.

operate-schema set will use --flush as default action #1724

Closed
lance6716 opened this issue May 26, 2021 · 1 comment · Fixed by #1799
Closed

operate-schema set will use --flush as default action #1724

lance6716 opened this issue May 26, 2021 · 1 comment · Fixed by #1799

Comments

@lance6716
Copy link
Collaborator

Feature Request

Is your feature request related to a problem? Please describe:

If we not --flush, which means write a table checkpoint, and following error happens, will cause "drop table in schema tracker because no checkpoint exists" so the operate-schema set is silently disappeared.

Describe the feature you'd like:

as title

Describe alternatives you've considered:

Teachability, Documentation, Adoption, Migration Strategy:

@lance6716
Copy link
Collaborator Author

seems we can't use --flush to create a table structure for fresh new tables 😂

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x78cb4ea]

goroutine 2896 [running]:
github.com/pingcap/dm/syncer.(*binlogPoint).MySQLLocation(0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
	/Users/lance/Projects/dm/syncer/checkpoint.go:141 +0x6a
github.com/pingcap/dm/syncer.(*RemoteCheckPoint).FlushPointWithTableInfo(0xc0003a6630, 0xc0014118c0, 0xc0023b59a4, 0x4, 0xc0023b59a8, 0x4, 0xc001496a80, 0x0, 0x0)
	/Users/lance/Projects/dm/syncer/checkpoint.go:575 +0x44b
github.com/pingcap/dm/syncer.(*Syncer).OperateSchema(0xc000a58380, 0x902f118, 0xc001d54240, 0xc0015bff20, 0x4, 0xc000a3f408, 0x8, 0xc0023e9498)
	/Users/lance/Projects/dm/syncer/schema.go:93 +0x234e
github.com/pingcap/dm/dm/worker.(*SubTask).OperateSchema(0xc0003ea540, 0x902f118, 0xc001d54240, 0xc0015bff20, 0x4094b5f, 0xc000202480, 0xc0ffffffff, 0xc000000000)
	/Users/lance/Projects/dm/dm/worker/subtask.go:541 +0x289
github.com/pingcap/dm/dm/worker.(*Worker).OperateSchema(0xc000752360, 0x902f118, 0xc001d54240, 0xc0015bff20, 0x0, 0x0, 0x0, 0x0)
	/Users/lance/Projects/dm/dm/worker/worker.go:918 +0x328
github.com/pingcap/dm/dm/worker.(*Server).OperateSchema(0xc000202480, 0x902f118, 0xc001d54240, 0xc0015bff20, 0xc000202480, 0xc001d54240, 0xc0013db918)
	/Users/lance/Projects/dm/dm/worker/server.go:808 +0x81d
github.com/pingcap/dm/dm/pb._Worker_OperateSchema_Handler(0x802c280, 0xc000202480, 0x902f118, 0xc001d54240, 0xc0015bfec0, 0x0, 0x902f118, 0xc001d54240, 0xc0008d7040, 0x93)
	/Users/lance/Projects/dm/dm/pb/dmworker.pb.go:2824 +0x395
google.golang.org/grpc.(*Server).processUnaryRPC(0xc000589680, 0x9055358, 0xc000589e00, 0xc0011b3b00, 0xc00058fad0, 0xabf3f30, 0x0, 0x0, 0x0)
	/Users/lance/Projects/go/pkg/mod/google.golang.org/grpc@v1.27.1/server.go:1024 +0xa23
google.golang.org/grpc.(*Server).handleStream(0xc000589680, 0x9055358, 0xc000589e00, 0xc0011b3b00, 0x0)
	/Users/lance/Projects/go/pkg/mod/google.golang.org/grpc@v1.27.1/server.go:1313 +0x13b8
google.golang.org/grpc.(*Server).serveStreams.func1.1(0xc00055d0a0, 0xc000589680, 0x9055358, 0xc000589e00, 0xc0011b3b00)
	/Users/lance/Projects/go/pkg/mod/google.golang.org/grpc@v1.27.1/server.go:722 +0xe7
created by google.golang.org/grpc.(*Server).serveStreams.func1
	/Users/lance/Projects/go/pkg/mod/google.golang.org/grpc@v1.27.1/server.go:720 +0xb9

cc @GMHDBJD How could we set checkpoint to avoid "drop table in schema tracker because no checkpoint exists"?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant