Question

I have a replica set configured with 3 servers:

  1. Primary
  2. Secondary
  3. Arbiter

For durability I am inserting new documents with w:majority.

What happens if my primary or secondary servers go down? Will my writes still be successful albeit less durable? What happens if the secondary and arbiter nodes go down -- will I still be able to write to the primary using the same w:majority?

Was it helpful?

Solution

Will my writes still be successful albeit less durable?

No since the majority of configured members is no longer up, plus the Arb is a non data holding node.

Edit

Misread the "or" for an "and".

If one goes down then writes will still continue, after an election if the primary goes but as you said they will be less durable due to the Arb being a non data holding node.

What happens if the secondary and arbiter nodes go down

Again the Primary will initiate an election and step down to a secondry when that election fails.

(You can set the vote settings of the other two to stop this but not sure if that's a good idea)

will I still be able to write to the primary using the same w:majority?

No only read from the once primary.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top