使用以下命令在服务器上恢复我的mongodb数据库时:
mongorestore -h ds023435*** :23445 -d idea(idea是我的数据库名称)
它显示以下错误:
Failed: idea.questions: error reading database: not authorized on idea to execute
command { listCollections: 1, cursor: { batchSize: 0 } }发布于 2017-08-17 03:23:27
你是不是用身份验证开始了Mongod.如果是,请在不开启鉴权的情况下重启mongod。使用下面的命令,它会工作得很好。
mongorestore转储
如果不起作用,请使用管理员权限打开新的命令提示符。然后执行命令。看起来不错。
https://stackoverflow.com/questions/38495843
复制相似问题