mongoshake同步使用all模式导致目标端主库服务器oom ,mongodb进程被kill
xiang-coco opened this issue · comments
mongoshake 版本:2.4.16
mongodb 源端版本:4.2.17
mongodb 目标端版本:4.2.17
目标端mongodb主库服务器日志(/var/log/message)如下:
Out of memory: Kill process 15483 (mongod) score 922 or sacrifice child
Killed process 15483 (mongod), UID 0, total-vm:15394224kB, anon-rss:13475680kB, file-rss:0kB, shmem-rss:0kB
mongoshake报错信息如下:
panic: send on closed channel
goroutine 1861 [running]:
vendor/github.com/vinllen/log4go.(*ConsoleLogWriter).LogWrite(0xc42029c600, 0xc420268680)
/home/zhuzhao.cx/mongo-shake/MongoShake/src/vendor/github.com/vinllen/log4go/termlog.go:41 +0x43
vendor/github.com/vinllen/log4go.Logger.intLogf(0xc42001f860, 0x5, 0xd02f75, 0x40, 0xc4299e9ea0, 0x3, 0x3)
/home/zhuzhao.cx/mongo-shake/MongoShake/src/vendor/github.com/vinllen/log4go/log4go.go:223 +0x289
vendor/github.com/vinllen/log4go.Warn(0xba4f80, 0xe1ba80, 0xc4299e9ea0, 0x3, 0x3, 0xc420214341, 0x12)
/home/zhuzhao.cx/mongo-shake/MongoShake/src/vendor/github.com/vinllen/log4go/wrapper.go:215 +0x35a
mongoshake/collector/docsyncer.(*DocExecutor).doSync(0xc4204007e0, 0xc423457800, 0x80, 0x80, 0x0, 0x0)
/home/zhuzhao.cx/mongo-shake/MongoShake/src/mongoshake/collector/docsyncer/doc_executor.go:195 +0x516
mongoshake/collector/docsyncer.(*DocExecutor).start(0xc4204007e0)
/home/zhuzhao.cx/mongo-shake/MongoShake/src/mongoshake/collector/docsyncer/doc_executor.go:154 +0xd7
created by mongoshake/collector/docsyncer.(*CollectionExecutor).Start
/home/zhuzhao.cx/mongo-shake/MongoShake/src/mongoshake/collector/docsyncer/doc_executor.go:75 +0x161