Failed to connect to 127.0.0.1:27017 reason: errno:111 connection attempt failed at src/mongo/shell/mongo.js:146

背景

今天打开mongo, 结果在命令行输入mongo后,报错如下

解决方法

四步

1) Remove .lock file

2) repair the mongodb

3) start the mongodb

4) start the mongo client

更多细节

http://shakthydoss.com/error-couldnt-connect-to-server-127-0-0-127017-srcmongoshellmongo-js-exception-connect-failed/

发表评论

电子邮件地址不会被公开。