install mongoDB (child process failed, exited with error number 100)

后端 未结 9 1378
梦谈多话
梦谈多话 2020-12-08 10:21

I tried to install mongoDB on my macbook air.

I\'ve downloaded zipped file from official website and extract that file and move to root directory. After that, under

相关标签:
9条回答
  • 2020-12-08 10:56

    Similar issue with the same error - I was trying to run the repair script sudo -u mongodb mongod -f /etc/mongodb.conf --repair

    Checked ps aux | grep mongo and see that the daemon was running. Stopped it and then the repair script run without an issue.

    Hope that could be helpful for someone else.

    0 讨论(0)
  • 2020-12-08 10:59

    create folder "data" and "db" inside it, in "/" path of your server. actually you should create or modify permissions of folder that the data is going to be stored!

    0 讨论(0)
  • 2020-12-08 11:05

    I had the same error. I ran it interactively to see the log.

    2014-10-21T10:12:35.418-0400 [initandlisten] ERROR: listen(): bind() failed errno:48 Address already in use for socket: 0.0.0.0:27017
    

    Then I used lsof to find out which process was using my port.

    $ lsof -i:27017
    COMMAND  PID     USER   FD   TYPE             DEVICE SIZE/OFF NODE NAME
    mongod  2106 MYUSERID   10u  IPv4 0x635b71ec3b65b4a1      0t0  TCP *:27017 (LISTEN)
    

    It was a mongod that I had forked previously and forgot to turn off (since I hadn't seen it running in my bash window). Simply killing it by running kill 2106, enabled my process to run without the error 100.

    0 讨论(0)
  • 2020-12-08 11:08

    Generally, this error comes when the mongod.conf file is not able to find a certain path for Database store or log store or maybe processid store or maybe it's not getting the file permission to access the config directories and files which has been declared in mongod.conf

    to resolve this error we need to observe the log generated by the MongoDB it will clearly indicate whether which file or directory you MongoDB is not able to access

    the above error may look like below screenshot

    0 讨论(0)
  • 2020-12-08 11:09

    I had the same error on linux (Centos) and this worked for me

    1. Remove mongod.lock from the dbpath

      $ rm /var/lib/mongo/mongod.lock

    2. Repair the mongod process

      $ mongod --repair

    3. Run mongod config

      $ mongod --config /etc/mongod.conf

    0 讨论(0)
  • 2020-12-08 11:17

    There was the same problem on my machine. In the log file was:

    Mon Jul 29 09:57:13.689 [initandlisten] ERROR: Insufficient free space for journal file
    Mon Jul 29 09:57:13.689 [initandlisten] Please make at least 3379MB available in /var/mongoexp/rs2/journal or use --smallfiles

    It was solved by using mongod --smallfiles. Or if you start mongod with --config option than in a configuration file disable write-ahead journaling by nojournal=true (remove the beginning #). Some more disk space would also solve the above problem.

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