Hello,
I am trying to implement the mongodb replicaset configuration here - [URL=“https://docs.mongodb.com/manual/core/inmemory/#replica-set”]https://docs.mongodb.com/manual/core...y/#replica-set[/URL]
With 3 replicas. The primary and second replica are both in memory. The 3rd is using WiredTiger.
However, when I restart the cluster the data does not persist, and I get this error on startup. I am deploying with kubernetes using the official mongodb replicaset helm chart ([URL=“charts/stable/mongodb-replicaset/templates at master · helm/charts · GitHub”]https://github.com/helm/charts/tree/...aset/templates[/URL]) with the percona mongodb image.
Server has startup warnings: 2020-03-19T12:55:06.993+0000 I REPL [conn6] 2020-03-19T12:55:06.993+0000 I REPL [conn6] ** WARNING: This replica set node is running without journaling enabled but the 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** writeConcernMajorityJournalDefault option to the replica set config 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** is set to true. The writeConcernMajorityJournalDefault 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** option to the replica set config must be set to false 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** or w:majority write concerns will never complete. 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** In addition, this node’s memory consumption may increase until all 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** available free RAM is exhausted. 2020-03-19T12:55:06.994+0000 I REPL [conn6] 2020-03-19T12:55:06.994+0000 I REPL [conn6] 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** WARNING: This replica set node is using in-memory (ephemeral) storage with the 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** writeConcernMajorityJournalDefault option to the replica set config 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** set to true. The writeConcernMajorityJournalDefault option to the 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** replica set config must be set to false 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** or w:majority write concerns will never complete. 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** In addition, this node’s memory consumption may increase until all 2020-03-19T12:55:06.994+0000 I REPL [conn6] ** available free RAM is exhausted. 2020-03-19T12:55:06.994+0000 I REPL [conn6]
rs0:PRIMARY> cfg = rs.conf() { “_id” : “rs0”, “version” : 102744, “protocolVersion” : NumberLong(1), “writeConcernMajorityJournalDefault” : false, “members” : [ { “_id” : 0, “host” : “mongodb-mongodb-replicaset-0.mongodb-mongodb-replicaset.default.svc.cluster.local:27017”, “arbiterOnly” : false, “buildIndexes” : true, “hidden” : false, “priority” : 1, “tags” : { }, “slaveDelay” : NumberLong(0), “votes” : 1 }, { “_id” : 1, “host” : “mongodb-mongodb-replicaset-1.mongodb-mongodb-replicaset.default.svc.cluster.local:27017”, “arbiterOnly” : false, “buildIndexes” : true, “hidden” : false, “priority” : 1, “tags” : { }, “slaveDelay” : NumberLong(0), “votes” : 1 }, { “_id” : 2, “host” : “mongodb-mongodb-replicaset-2.mongodb-mongodb-replicaset.default.svc.cluster.local:27017”, “arbiterOnly” : false, “buildIndexes” : true, “hidden” : true, “priority” : 0, “tags” : { }, “slaveDelay” : NumberLong(0), “votes” : 1 } ], “settings” : { “chainingAllowed” : true, “heartbeatIntervalMillis” : 2000, “heartbeatTimeoutSecs” : 10, “electionTimeoutMillis” : 10000, “catchUpTimeoutMillis” : -1, “catchUpTakeoverDelayMillis” : 30000, “getLastErrorModes” : { }, “getLastErrorDefaults” : { “w” : 1, “wtimeout” : 0 }, “replicaSetId” : ObjectId(“5e736baa5c51ff3e198dd880”) } }
The writeConcernMajorityJournalDefault IS set to false.
I would very much appreciate any help, and am happy to contribute back the helm chart for anyone else who wants this configuration!