How to set mongod.conf bind_ip with multiple ip address

前端 未结 16 625
情书的邮戳
情书的邮戳 2020-12-09 01:22

I am a newbie for setting up the server environment and mongoDB. This may sounds something really simple, however, I really need your help on it.

I am trying to conn

16条回答
  •  甜味超标
    2020-12-09 02:05

    If all you want to do is connect to this machine over the network you do NOT need to modify the bind_ip value.

    In your case you need to follow the following steps.

    1. Setup the remote machine to block all connections to port 27017
    2. Enable remote machine to only accept connections from your local machine
    3. Setup credentials with MongoDB
    4. Connect with client using credentials.

    If you are not sure how to do any of this steps. Check out a blog post that I wrote that goes more in details how to do this.

    Blog Post

    Hope this helps.

提交回复
热议问题