Currently we have the issue with Operator 1.7 that we have a lot of collections and index files open. After 100’000s (27.7h) the file_manager in MongoDB starts to act and release the files. So if 200’000 files are open and according to the file_manager config (hardcoded by Percona) it releases down to 250 files, MongoDB tries to release them basically at once which causes the liveness probe to fail (I’ve tuned it already to the max). So that means all 3 pods of the replica set get killed and the startup takes like 1h to read all the files again.
Our current workaround is to change a value in cr.yaml and apply it (kubectl apply -f my_changed_cr.yaml). The mongod pods restart each after the other - so no interruption. Also the file_manager counter gets resetted and the replica set runs stable for the next 24h
Since this is a little bit painful, is there a way how we can apply a value to the PerconaMongoDB specifially with a kubectl patch or so ? How can we set a specific value in “PerconaMongoDB” … I mean I just dont get how to access PerconaMongoDB in order to set for example the request / cpu.
Or does a command exist, where I can say “pls safely restart all my mongod pods w/o service interruption”
Just to get an idea …
kubectl patch statefulset xxx-mongodb-cluster-rs0 -p '{"spec":{....}}'
but the issue is, it seems it has to go to the PerconaMongoDB, if patching the statefulset then there is no PRIMARY/SECONDARY selection going on and therefore the cluster is at some point unavailable.
replicaset.apps/xxx-mongodb-cluster-mongos-664db85886 3 3 3 16d
replicaset.apps/percona-server-mongodb-operator-586b769b44 1 1 1 63d
statefulset.apps/xxx-mongodb-cluster-cfg 3/3 16d
statefulset.apps/xxx-mongodb-cluster-rs0 3/3 16d