46

I signed up freely at MongoDB Atlas and created cluster now I want to know how can I create database and connect to that using Robomongo?

4

9 回答 9

101

1) (Atlas Mongodb console)First of all click on ALLOW ACCESS FROM ANYWHERE(see in below image) and put some random IP address , don't click on Add Current IP Address otherwise it will not connect with robomongo .

pic1

2) Now open robomongo ,select connection Tab and then select type Direct Connection , and put your primary cluster in Address [you can get your Primary Cluster Address from Project->Clusters->(choose) Primary Cluster-> "There you will find your Primary Cluster Address"] .

pic2

3)now click on Authentication Tab , put database name is admin and put your username and password , Auth Mechanism is SCRAM-SHA-1.

pic3

4) select self-signed certificate as Authentication Method

pic4

5) Now , click on test,we are done ! pic5

The standard Mongo URI connection schema has the form:

 mongodb://[username:password@]host1[:port1][,...hostN[:portN]]][/[database][?options]]

Security Reasons

  1. Do not allow access everywhere for security reasons
  2. Restrict to your IP address
  3. Connect via roboMongo 3T using a secondary cluster node from MongoDB Atlas
于 2017-10-25T18:31:35.633 回答
13

In case it helps others, Robo3Tversion 1.3 and greater has a "From SRV" field where you can paste the SRV connection string and it fills out the connection options correctly for you. As of 1.3 it looks like this:

From SRV

As of writing, you can get the connection string by clicking the "connect" button next to your cluster dashboard's graphs, and then clicking "Connect your application", and you get a screen like this with the connection string that you can copy:

connection string in mongodb atlas

于 2019-07-20T08:23:10.013 回答
12

@kdblue, It's not working for me. But when I tried using the replica set, I could able to connect successfully.

Robo 3T Version: 1.2.1

Steps followed:

In your MongoDB Atlas(cloud.mongodb.com), copy all the three replica sets name and note it down. (Refer an image for reference, the replica sets denoted in the orange box).

enter image description here

Now, in your Robo 3T, in Connection tab, select type as Replica Set. Provide a suitable name for your connection. And now in Members, add all the three copied replica sets. Refer image for details.

enter image description here

Provide authentication, if you have any and follow SSL steps (mandatory) as suggested by @kdblue in the previous answer.

You could able to connect successfully now.

Thank you.

于 2018-10-12T03:06:35.283 回答
4

[Updated]

It is now possible to connect to Mongo Atlas 3.4 free cluster with the latest beta: Robomongo 1.1 - Beta version with MongoDB 3.4 Support

于 2017-05-02T07:17:46.143 回答
2

Direct connections do not work with Replica Sets and Robo3T.
And the cluster you create on Atlas is a 3-Node replica set.

Select Connection Type: Replica Set on the first tab

To find out 3 members in new Atlas dashboard:

  1. click on Clusters in your Atlas dashboard.
  2. click collections button on the cluster.
  3. click Overview tab on the next menu.

you will see the list of your set (primary and two secondary).

then follow @Balasubramani M's answer.

于 2019-08-05T07:08:46.830 回答
0

Instead of connecting it with robomongo I would recommend you to connect it with COMPASS. That is a opensource GUI tool for connecting to your MongoDB Atlas deployment and it is supported by MongoDB people also.

You can download compass from https://www.mongodb.com/download-center/compass.

Additionally many functionalities are not supported in robomongo.

Robo mongo is the 3rd party tool so even if you go the mongodb people they will not support.

Instruction for connecting your atlas cluster with compass can be found in the documentation https://docs.atlas.mongodb.com/compass-connection/

However, even after following my response you encounter any issue, let me know , I will help you further.

于 2020-03-25T09:45:38.533 回答
0

If you have the "TLS" instead of the "SSL" tab, don't get crazy.

Just do exactly the same that you would do with "SSL":

  1. Mark the "Use TLS protocol" checkbox
  2. Choose the "Self-signed Certificate" authentication method option

And that's all!

于 2020-11-04T15:04:57.207 回答
0

No matter what I tried it wouldn't work, all I had to end up doing was update to the latest version at which point my old connection setup worked fine.

https://robomongo.org/download

于 2021-04-11T10:16:09.893 回答
-1

Tip: I struggled updating a connection, no dice.

Created one form scratch using above and connected on first attempt.

于 2018-11-27T19:54:26.407 回答