EFS Volume Fails to Mount on Kubernetes Pod
By : Josh -
I was migrating a site from AWS ECS to AWS EKS recently, using the bitnami/wordpress helm chart and came across the following error:
E0915 00:48:16.726703 1 driver.go:103] GRPC error: rpc error: code = Internal desc = Could not mount "fs-a031e6a6:/" at "/var/lib/kubelet/pods/5c4bb6c6-76c6-4375-bb5b-22605264bca6/volumes/kubernetes.io~csi/pvc-afc4ab14-6cf8-4861-b058-e7aedf195395/mount": mount failed: exit status 32 Mounting command: mount Mounting arguments: -t efs -o accesspoint=fsap-06dec0e6d9aca8217,tls fs-a031e6a6:/ /var/lib/kubelet/pods/5c4bb6c6-76c6-4375-bb5b-22605264bca6/volumes/kubernetes.io~csi/pvc-afc4ab14-6cf8-4861-b058-e7aedf195395/mount Output: Could not start amazon-efs-mount-watchdog, unrecognized init system "aws-efs-csi-dri" b'mount.nfs4: access denied by server while mounting 127.0.0.1:/'
I spent quite a while troubleshooting this error, and the result was actually not related to this output at all. This output was due to the wordpress pod coming online before the EFS access point was initialized as part of the persistent volume claim that triggered a dynamic volume from AWS EFS using the CSI driver. Once the container restarted, it was able to access the EFS volume without issue.