amazon-web-serviceskubernetesamazon-eksamazon-ebs

Single EBS volume shared by multiple EC2 nodes in a EKS/K8s cluster


I would like to determine if a data storage scenario described below is possible with AWS EKS/Kubernetes. Here is the spec:

The goal here is to use the multi-attach EBS drive as a stand-in for a database. We want data to be accessible by several EC2 nodes, see note 1.

As far as I can tell, the EBS driver for EKS does not support multi-attach drives (stackoverflow, github issue).

So then my other option is to directly configure the nodes in the auto-scaling group to mount the EBS volume as part of their initial start-up. Then, use a local PV type in the K8s manifest.

Is this second option technically viable?

Foot Notes

1 Why are we not using an actual database, or an EFS? Because they are too slow. We have a bit of a special use case, where we are trying to establish a multi-gigabyte-per-second read rate between compute and storage, and on AWS that can only (?) be achieved with an IO optimized EBS drive directly attached to an EC2 node.


Solution

  • Version 1.25.0 of AWS EBS CSI Driver just released includes this functionality. Perhaps this is now a possibility for you?

    https://github.com/kubernetes-sigs/aws-ebs-csi-driver/blob/master/CHANGELOG.md