mountpoint-s3-csi-driver: Driver name s3.csi.aws.com not found in the list of registered CSI drivers
/kind bug
What happened?
When mounting the volume on the pod, it cannot locate the drive
Warning FailedMount 12s (x8 over 76s) kubelet MountVolume.MountDevice failed for volume “s3-pv” : kubernetes.io/csi: attacher.MountDevice failed to create newCsiDriverClient: driver name s3.csi.aws.com not found in the list of registered CSI drivers
What you expected to happen?
That it can normally mount the volume without failure
How to reproduce it (as minimally and precisely as possible)?
Apply the example yaml
apiVersion: v1
kind: PersistentVolume
metadata:
name: s3-pv
spec:
capacity:
storage: 120Gi # ignored, required
accessModes:
- ReadWriteMany # supported options: ReadWriteMany / ReadOnlyMany
mountOptions:
- allow-delete
- region us-east-1
csi:
driver: s3.csi.aws.com # required
volumeHandle: s3-csi-driver-volume
volumeAttributes:
bucketName: s3-csi-driver-private
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: s3-claim
spec:
accessModes:
- ReadWriteMany # supported options: ReadWriteMany / ReadOnlyMany
storageClassName: "" # required for static provisioning
resources:
requests:
storage: 120Gi # ignored, required
volumeName: s3-pv
---
apiVersion: v1
kind: Pod
metadata:
name: s3-app
spec:
containers:
- name: app
image: centos
command: ["/bin/sh"]
args: ["-c", "echo 'Hello from the container!' >> /data/$(date -u).txt; tail -f /dev/null"]
volumeMounts:
- name: persistent-storage
mountPath: /data
volumes:
- name: persistent-storage
persistentVolumeClaim:
claimName: s3-claim
Anything else we need to know?:
kc get pvc
NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS AGE
s3-claim Bound s3-pv 120Gi RWX 4m47s
kc get pv
s3-pv 120Gi RWX Retain Bound kube-system/s3-claim
kubectl get csidriver
NAME ATTACHREQUIRED PODINFOONMOUNT STORAGECAPACITY TOKENREQUESTS REQUIRESREPUBLISH MODES AGE
ebs.csi.aws.com true false false <unset> false Persistent 48d
efs.csi.aws.com false false false <unset> false Persistent 48d
s3.csi.aws.com false false false <unset> false Persistent 135m
kc get storageClass
NAME PROVISIONER RECLAIMPOLICY VOLUMEBINDINGMODE ALLOWVOLUMEEXPANSION AGE
gp2 kubernetes.io/aws-ebs Delete WaitForFirstConsumer false 203d
gp3 (default) kubernetes.io/aws-ebs Delete WaitForFirstConsumer false 203d
Is it necessary to create a new storage class?
kc logs pod/s3-csi-node-r2w75
Defaulted container "s3-plugin" out of: s3-plugin, node-driver-registrar, liveness-probe, install-mountpoint (init)
I1212 16:35:21.276393 1 driver.go:61] Driver version: 1.1.0, Git commit: c681ab1f19ccba5976e3263f0e3df65718750369, build date: 2023-12-05T19:47:03Z, nodeID: ip-0-00-0-00.ec2.internal, mount-s3 version: 1.3.1
I1212 16:35:21.282921 1 mount_linux.go:285] 'umount /tmp/kubelet-detect-safe-umount3132235530' failed with: exit status 32, output: umount: /tmp/kubelet-detect-safe-umount3132235530: must be superuser to unmount.
I1212 16:35:21.282946 1 mount_linux.go:287] Detected umount with unsafe 'not mounted' behavior
I1212 16:35:21.289423 1 driver.go:83] Found AWS_WEB_IDENTITY_TOKEN_FILE, syncing token
I1212 16:35:21.289599 1 driver.go:113] Listening for connections on address: &net.UnixAddr{Name:"/csi/csi.sock", Net:"unix"}
I1212 16:35:22.113470 1 node.go:204] NodeGetInfo: called with args
kc describe sa s3-csi-driver-sa
Name: s3-csi-driver-sa
Namespace: kube-system
Labels: app.kubernetes.io/component=csi-driver
app.kubernetes.io/instance=aws-mountpoint-s3-csi-driver
app.kubernetes.io/managed-by=EKS
app.kubernetes.io/name=aws-mountpoint-s3-csi-driver
Annotations: eks.amazonaws.com/role-arn: arn:aws:iam::0000000:role/TMP_AmazonEKS_S3_CSI_DriverRole
Image pull secrets: <none>
Mountable secrets: <none>
Tokens: <none>
Events: <none>
Environment
- Kubernetes version (use
kubectl version):
Client Version: version.Info{Major:"1", Minor:"27", GitVersion:"v1.27.3", GitCommit:"25b4e43193bcda6c7328a6d147b1fb73a33f1598", GitTreeState:"clean", BuildDate:"2023-06-14T09:47:38Z", GoVersion:"go1.20.5", Compiler:"gc", Platform:"darwin/amd64"}
Kustomize Version: v5.0.1
Server Version: version.Info{Major:"1", Minor:"25+", GitVersion:"v1.25.15-eks-4f4795d", GitCommit:"9587e521d190ecb7ce201993ceea41955ed4a556", GitTreeState:"clean", BuildDate:"2023-10-20T23:22:38Z", GoVersion:"go1.20.10", Compiler:"gc", Platform:"linux/amd64"}
WARNING: version difference between client (1.27) and server (1.25) exceeds the supported minor version skew of +/-1
- Driver version: v1.1.0-eksbuild.1
About this issue
- Original URL
- State: open
- Created 3 years ago
- Reactions: 2
- Comments: 21 (5 by maintainers)
Reopened, thanks for the callout! We are working on fixing the issue described in the original report and will provide an update as soon as we have an ETA.
Hey, I have noticed this issue as well. Usually it happens when the pod with mounted volume spawns before the
s3-csipod in a recently spawned node. But, usually, after a while my pod resumes normally.This is an error I have had before using other CSIs, such as FSx CSI, and they have a mechanism with startup taints to prevent pods to start before the CSI pod is present.
This is the reference for FSx CSI taint:
Hope this helps somehow! 😃
Could someone reopen this issue? It’s not actually fixed.
There were two parallel discussions in this thread. The first, starting from the original report, is that pods depending on the S3 Mountpoint CSI driver can execute before the CSI driver pod itself is actually ready, leading to pods receiving the error described at the top:
driver name s3.csi.aws.com not found in the list of registered CSI drivers. The second discussion came from a question about the CSI pods themselves tolerating taints on nodes to ensure they can even be scheduled, which, though instructive, had nothing to do with the original report.@patrickpa noted the fix in his comment. We need the ability to configure startup taints on nodes that will host the CSI driver, and the CSI driver needs to clear the taint once it’s ready.
That the EKS Addon now supports configuring tolerations for the driver itself is helpful, but it has nothing to do with addressing the original issue.
v1.8.0 of our EKS add-on has been released with
node.tolerateAllTaintsandnode.tolerationsconfiguration values:You can set
node.tolerateAllTaintstotrueif you want CSI driver’s Pods to schedule all nodes in the cluster, or you can configurenode.tolerationsarray if you need more granularity.For example:
Closing the issue now. Could you please try upgrading to v1.8.0 with a toleration config to see if that solves the problem? Please let us know if the issue persists.
If i understand it correctly then the CSIDriver is in place but the resource can’t find it. Then i think it is rather a problem with your api-server then with the csi driver itself. But i don’t have a clou how to solve this. Sorry.