mongodump stdout用于集合不工作

时间:2012-03-01 05:57:00

标签: mongodb

所以我试图通过stdout在mongodump上转储一个集合,这样我就可以直接管道并gzip了。但它给了我错误。

当我这样做时:

mongodump --db test -u username -p Password -h mymongodatabase.onthecloud:12888 -vvvvv --collection posts --out -

显示以下错误:

Wed Feb 29 21:48:13 creating new connection to:mymongodatabase.onthecloud:12888
Wed Feb 29 21:48:13 BackgroundJob starting: ConnectBG
Wed Feb 29 21:48:13 connected connection!
connected to: mymongodatabase.onthecloud:12888
Wed Feb 29 21:48:13 nextSafe(): { $err: "unauthorized db:test lock type:-1 client:10.3.55.10", code: 10057 }
Wed Feb 29 21:48:13 User Assertion: 13106:nextSafe(): { $err: "unauthorized db:test lock type:-1 client:10.3.55.10", code: 10057 }
assertion: 13106 nextSafe(): { $err: "unauthorized db:test lock type:-1 client:10.3.55.10", code: 10057 }

但是当我试图包含'--out - '时,它会将收集转移得很好(不会给我一个错误的错误)。发生了什么事?

1 个答案:

答案 0 :(得分:1)

这是一个错误,已发布并修复:

https://jira.mongodb.org/browse/SERVER-5233