AWS DocumentDB with Robo 3T (Robomongo)
Asked Answered
N

4

14

I want to connect Robo 3T (formerly robomongo) from my Mac laptop with AWS's DocumentDB. I followed numerous tutorials however could not find any specific to DocumentDB.

During the testing phase it passes step #1 "connected to my EC2 instance", however fails on step #2 with the message "failed to connect to ...docdb.amazonaws.com:27017 via SSH tunnel". Has anyone been able to get this to work?

Nonunion answered 27/1, 2019 at 1:3 Comment(1)
Attention: Curently it is not possible with Robo 3T to edit documents in DocumentDB -> #57329123Sharlenesharline
P
21

here is my config in five scree-shots. Connection Tab Authentication Tab SSH Tunnel SSL Advanced

Pawpaw answered 5/5, 2019 at 19:23 Comment(1)
This, combined with the ssh command from Arun Ramachandran got it working. Remember, default db is the name of your db. It's not admin.Bottommost
E
10

Steps to connect from Robo 3T

 1. Host : localhost and 28017: source port that we mentioned in ssh
    tunnel
 2. Authentication tab - Database : DBname; Username and password of
    the documentDb
 3. In SSL tab, click Use SSL protocol
 4. Click use CA certificate
 5. Import the CA certificate in .pem format. Download it from this link
    : https://s3.amazonaws.com/rds-downloads/rds-combined-ca-bundle.pem
 6. Click on Advanced options and keep Invalid hostnames : Allowed
 7. Give a name for the connection and hit connect button.
 8. Connection should be established by now.

I assume you use the below command for SSH tunnel.

ssh -i "ec2Access.pem" -L 28017:sample-cluster.cluster-cu52jq5kfddg.us-east-1.docdb.amazonaws.com:27017 [email protected] -N 

Hope this will work.

Expire answered 5/2, 2019 at 15:24 Comment(3)
Thank you. I had to do some additional environment specific settings, but ended up getting it to work.Nonunion
the only step that was missing was the Allow Invalid HostnamesPawpaw
@Nonunion What your additional setup?Mesomorphic
S
4

Via SSH-Tunnel on macOS this seems the way to got (fiddled around with the CA-pem without success before):

SSL settings macOS Robo 3T

Sharlenesharline answered 19/6, 2020 at 13:20 Comment(0)
E
4

For those who still get stuck with the problem, there's a detailed guide at https://aws.amazon.com/blogs/database/part-3-getting-started-with-amazon-documentdb-using-robo-3t/

One important note is that the EC2 for SSH tunnel and the DocumentDB cluster must be in the same VPC (not necessarily the same Security Group if they opened the needed port (22 & 27017 for example) ). Furthermore, you should create a testing database & insert at least one document in order to set the Authentication for Robo3T connection as of

"On the Authentication tab, enter the authentication information for your cluster. Make sure to use a custom database name like ‘test’ or ‘testdb’. Using ‘admin’ (default setting) does not work for DocumentDB for clusters with no databases. Once you have created your first database you can modify your connection to use ‘admin’."

Hope it help!!

Eulogia answered 23/6, 2020 at 2:32 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.