skip to Main Content

I’ve tried this syntax,

bindIp = [127.0.0.1, 192.168.184.155, 96.88.169.145]

But it’s not working at all saying unable to start mongod service. I’m using centos 7 and everything else works except when I try to use multiple IPs in the MongoDB config, then mongod service fails to start.

2

Answers


  1. Can you try like this ,

    bindIp = 127.0.0.1, 192.168.184.155, 96.88.169.145

    Then restart Mongod

    sudo service mongod restart
    
    Login or Signup to reply.
  2. The config file is a YAML format, so config valures are given as key: value (not key = value)

    Try these ones:

    bindIp: [127.0.0.1, 192.168.184.155, 96.88.169.145]
    

    or

    bindIp: 
      - 127.0.0.1
      - 192.168.184.155
      - 96.88.169.145
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search