Pod fails to start: failed to open bolt file: open /vault/data/vault.db: permission denied

Hey all

I am fairly new to K8s and vault.

I am attempting to setup vault using the HELM chart with HA enabled utilizing raft storage. Anytime I attempt to initalize I receive the following error on my k8s pods

“Error initializing storage of type raft: failed to create fsm: failed to open bolt file: open /vault/data/vault.db: permission denied”

I have ensured that my PV and PVC are set up properly and my PV is bound to the pod. We are using GlusterFS for the volume.

I have also tried setting up an initContainer to update the perms for that directory and that did not help the issue either.

Any help would be greatly appreciated.

When Kubernetes mounts a PV, it is supposed to set the ownership of the directory to match the pod it is being mounted into.

It sounds like this is, for some reason, not happening.

However, I’ve not worked with GlusterFS, so I’m not sure why that might be.