2

I'm baffled by an issue that just started on my multi-node kubernetes cluster (I run it with microk8s):

Error: failed to prepare subPath for volumeMount "scripts" of container "zookeeper" 

The config that triggers this error is:

 volumeMounts: - name: scripts mountPath: /scripts/setup.sh subPath: setup.sh - name: data mountPath: /bitnami/zookeeper 

I have had this config for a couple of years and there has never been a problem up until now. Even more strange, it happens for all the deployments that use subpath, on all my nodes. Anything with this pattern:

 - mountPath: /mounted_path name: volume_name subPath: a_sub_path 

It's very intriguing because it just started, I can see this behaviour on v1.31.6 and v1.32.2.

I use host path a lot, through the hostpath-storage addon. I haven't deleted/created/changed the permissions of any of the directories referenced in the volumes.

Would you have an idea about why this is happening?

1 Answer 1

2

The latest util-linux update v2.41 includes a regression in the mount commands option -no-canonicalize which is used by kubernetes. A fix for this is merged in util-linux and will be included in the next release. (https://github.com/util-linux/util-linux/issues/3474)

Until then, the issue can be avoided by downgrading util-linux to the last unaffected version v2.40.3.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.