top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

Can we connect to Mongo DB without Mongos when we are not using Sharded Cluster ?

+1 vote
324 views

I am in the process of migrating a replica set from a data center to AWS, but when I checked the settings, I noticed that the Sharding is not enabled, yet they are using 3 MongoS / Routers and 3 MongoC / Config servers - So since Sharding is not used in the current system, would it be safe to migrate the replica sets and not use MonogoS nor MongoC ? Can the users connect directly to Mongo database replica set without using MongoS ?
Or should I use at least 1 MongoS and 1 MongoC config server ?

posted Sep 19, 2015 by anonymous

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+1 vote

I am creating a sharded cluster with a 2 node config server replicaset.Due to some reason, the config server replicaset did not get created/setup properly.At this time, I started a mongos process configured to connect to this CSRS and on that box, I see lot of mongos processes getting created

Why wouldnt the mongos process just fail instead of keeping re-spawning and trying to connect to the CSRS? Related to this, how do we check (from an external script) that the CSRS is up & available before starting a mongos process?

The docs (https://docs.mongodb.com/manual/tutorial/troubleshoot-sharded-clusters/#sharding-config-servers-and-availability ) do mention that the CSRS should be available when you first initiate a sharded cluster, but does not mention how to do it.

0 votes

If you wanted to copy over the mongo database using mongos oplog, how would you do it? Suppose we start copying the database at time T and we finish the copying at time U. We have to read from the oplog from time T onward and apply oplog changes (which also may have been applied between time T and U). Do the oplog transactions have timestamps in them so we can discard records before time T? Are the operations idempotent if we apply them twice (because we are applying an operation already executed between time T and U)? Guess I am confused how to get the initial data before reading from the oplog to continue the real time updates.

+1 vote

I am new to ruby on rails (using rails 4 and ruby 2.0.0) and I'm looking for a good tutorial for mongo db using mongoid.yml.

I found a few online, but they give only the basic steps. And I have done till that. ie. insert, query, etc from a mongo db database through the controller.

My basic question revolves around making a connection pool and using it. What changes to do it the mongoid.yml and how to (in java terms) getConnection from the controller???

Any help would be appreciated?

...