MountVolume.MountDevice failed for volume "pvc": rpc error: code = Internal desc = could not format "/dev/xvdac", mount failed: exit status 32, mount(2) system call failed: File exists.

0

I have my kubernetes cluster on aws instances, spinned up using kubedadm. I am using aws-ebs to allocate persisntant volumes to my redis pods. While spinning up the pod and attach pvs to the pods, they are being created on volumes and getting attached to the instance but they are not getting mounted to the pods. looks like only one pvc is not getting attached. I am not able to understand why and how. I am using t2.xlarge instances. calico network plugin.

lsblk

Enter image description here kubectl describe pod redis-stack-1 -n redis Enter image description here

root@ip-10-0-1-10:~/manifests/redis# kubectl get statefulset -n redis -o wide
NAME          READY   AGE   CONTAINERS   IMAGES
redis-stack   1/2     14m   redis        redis/redis-stack-server:latest
lc
asked 19 days ago157 views
1 Answer
0

FINALLY FOUND THE ISSUE: Output: mount: /var/lib/kubelet/plugins/kubernetes.io/csi/ebs.csi.aws.com/bb418c99aacece30013bb68ec90d5d3646149b8c04d296c6d1b66b5546a05bd3/globalmount: mount(2) system call failed: File exists.

This part of the error is important. So, i spun up a pod to use a pvc to test the allocation of the volume. and then i deleted the pvc. it is in terminating stage. I never gave much thought to it.

Then after getting stressed over it for 10hrs. and restarting it after 5hrs helped me to think calm. so i saw that a pod is still running that is using the ebs claim, I deleted the pod and then the pvc. immediately the volume got allocated to redis pod and the redis pods are running.

lc
answered 18 days ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions