I have a droplet server with an instance of mongodb on it. I can connect via SSH and view mongodb, however I really want to connect it to compass. However I keep getting ‘connect ECONNREFUSED’ error.
I’ve tried combinations of using localhost, my ip, different ports (as per what I’ve found via ssh) but still same error. If I try my ip:3000 interestingly it does attempt to connect but then I get an ‘invalid max size’ error or something like that.
I checked another ticket and also tried accessing in Compass using SSH tunnel but same ECONNREFUSED. What else can I check to get this fixed?
Thanks,
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi there,
In order to connect remotely to your MongoDB instance, you need to configure it to allow remote connections as described in this tutorial:
For anyone using a Managed MongoDB cluster, you can follow the steps here instead:
https://dev.to/digitalocean/how-to-easily-connect-to-digitaloceans-managed-mongodb-5gd1
Best,
Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
From GPU-powered inference and Kubernetes to managed databases and storage, get everything you need to build, scale, and deploy intelligent applications.