0

We use a MongoDB replica set, where after some time the primary set will throw the exception below and cannot recover from it. The error occurs only when we run the server in Replicaset mode.

Invariant failure !"WriteConflictException not allowed in saveState" src/mongo/db/query/plan_yield_policy.cpp 95

After the above error, none of the MongoDB servers (in the replica set) are available and the following message is repeated in the mongo.log:

REPL [ReplicationExecutor] stepping down from primary, because a new term has begun: 32

This is my server configuration:

Server 1:

  • MongoDB (Percona version 3.2.4-1.0rc2)
  • MongoDB Arbiter (Percona version 3.2.4-1.0rc2)

Server 2:

  • MongoDB (Percona version 3.2.4-1.0rc2)
Vince Bowdren
  • 8,326
  • 3
  • 31
  • 56
UshaP
  • 1,271
  • 2
  • 18
  • 32
  • Have you tried the same thing with official MongoDB release? (might be a Percona bug). Also, what version of the client are you using? – Nic Cottrell May 18 '16 at 09:57
  • No we haven't tried without the Percona. We're using Mongoose 4.4.17 – UshaP May 18 '16 at 10:40
  • Two immediate comments: firstly, you should really be running the arbiter on a different server, in case Server 1 goes completely offline leaving only a single node on Server 2. Secondly, what is the health of the replicaset after the primary has failed? You can find out with the [rs.status()](https://docs.mongodb.com/manual/reference/method/rs.status/) call. – Vince Bowdren Sep 06 '16 at 12:17

0 Answers0