-
Type: Task
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 1.8.5
-
Component/s: Replica Set
-
None
-
Environment:ruby mongo v1.8.5, mongod v2.2.4, ruby 2.0.0, client running on Mac OSX 10.8.3, mongod presumably some Linux in ec2
Hello I'm currently having problems connecting to a managed replica set hosted on Mongolab. Executing (for example) a count query on a Mongo::DB instance obtained via:
Mongo::MongoClient.from_uri(ENV['MONGOLAB_URI']).db['collection_name'] I get the following unauthorized message:
Mongo::OperationFailure: Database command 'count' failed: (assertion: 'unauthorized db:xxx ns:xxx.collection lock type:0 client:xxx'; assertionCode: '10057'; errmsg: 'db assertion failure'; ok: '0.0').
This also occurs when I attempt to connect to (and query) Mongolab's test replication nodes here: http://mongolab.org/flip-flop/
...using the MONGODB_URI mongodb://testdbuser:testdbpass@flip.mongolab.com:53117,flop.mongolab.com:54117/testdb
Also Mongoid is able to read and write to the replica set above as well.
Am I missing something fairly obvious here?
Thank you, Whitney
- is duplicated by
-
RUBY-606 Support auth params in Mongo::MongoReplicaSetClient.from_uri
- Closed