Reputation: 119
When I tried to connect to mangolab, I get Err ECONNRESET
var mongo = require("mongodb").MongoClient;
var assert = require('assert');
var url = "mongodb://username:password@urlForServer:port/databaseName";
mongo.connect(url, function(err, db) {
console.log(err);
});
I have put right info in connection url. please help.
Thanks in advance.
Upvotes: 0
Views: 15227
Reputation: 8380
I had a similar issue and it was due to corporate network restrictions which could be your case also
Your network may not allow this type of connection to this external address and port
Upvotes: 8