Mongodb: Failed to connect to 127.0.0.1:27017, reason: errno:10061

后端 未结 17 2208
醉话见心
醉话见心 2020-11-29 19:12

Here is my mongod.cfg file:

bind_ip = 127.0.0.1
dbpath = C:\\mongodb\\data\\db
logpath = C:\\mongodb\\log\\mongo-server.log
verbose=v

相关标签:
17条回答
  • 2020-11-29 19:37

    Normal case, you need at least 3379 MB of disk space. If you do not have;

    mongod.exe --smallfiles
    

    This is not the only requirement. But this may be your problem.

    0 讨论(0)
  • 2020-11-29 19:37

    I started mongod in cmd,It threw error like C:\data\db\ not found. Created folder then typed mongod opened another cmd typed mongo it worked.

    0 讨论(0)
  • 2020-11-29 19:39

    Try this, it worked for me.

    mongod --storageEngine=mmpav1
    
    0 讨论(0)
  • 2020-11-29 19:40

    When you typed in the mongod command, did you also give it a path? This is usually the issue. You don't have to bother with the conf file. simply type

    mongod --dbpath="put your path to where you want it to save the working area for your database here!! without these silly quotations marks I may also add!"

    example: mongod --dbpath=C:/Users/kyles2/Desktop/DEV/mongodb/data

    That is my path and don't forget if on windows to flip the slashes forward if you copied it from the or it won't work!

    0 讨论(0)
  • 2020-11-29 19:42

    I was also faced the same issue with mongodb 2.6.

    What solved my problem was I just run mongod --repair command

    and then start mongod.exe

    It's worked for me

    0 讨论(0)
  • 2020-11-29 19:43

    The Port is not open. Thats why the machine refuses communication

    0 讨论(0)
提交回复
热议问题