Slide 1

Slide 1 text

Introduction to Container Storage Interface (CSI)

Slide 2

Slide 2 text

What is Container Storage Interface (CSI) ? • an initiative to unify the storage interface of Container Orchestrator Systems (COs) like Kubernetes, Mesos etc. combined with storage vendors like Ceph, Portworx, NetApp etc. • a single CSI for a storage vendor is guaranteed to work with all COs.

Slide 3

Slide 3 text

Challenges with existing Storage Interfaces • CLI-based interface • Lack of idempotency on APIs • In-tree Interface • Tightly coupled with an implementation • Too Heavyweight.

Slide 4

Slide 4 text

CSI : Goals • Interoperability • Vendor Neutral • Focus on Specification • Control Plane Only • Keep It Simple !

Slide 5

Slide 5 text

CSI : High Level Architecture Ref: CloudNativeCon EU 2018 CSI Jie Yu

Slide 6

Slide 6 text

CSI Plugins: Design Considerations • Out of tree plugins • All Functionality is implemented as a service • Segregation between Controller and Node Services. • Idempotency • Wire protocol: gRPC • Synchronous APIs.

Slide 7

Slide 7 text

Deep Dive into the CSI Architecture Ref: https://medium.com/google-cloud/understanding-the-container-storage-interface-csi-ddbeb966a3b

Slide 8

Slide 8 text

Ref: https://medium.com/google-cloud/understanding-the-container-storage-interface-csi-ddbeb966a3b 3rd Party External Components 3 major sub-components: • CSI Identity : is mainly for identifying the plugin service, making sure it’s healthy, and returning basic information about the plugin itself. • CSI Controller : is responsible of controlling and managing the volumes, such as: creating, deleting, attaching/detaching, snapshotting, etc. • CSI Node: is responsible for controlling volume’s action in the Kubernetes node.

Slide 9

Slide 9 text

CSI Plugin Components Ref: https://www.snia.org/sites/default/files/SDCIndia/2019/PDF/3%20-%20Container%20Storage%20Interface%20for%20Kubernetes.pdf

Slide 10

Slide 10 text

Packaging and Deploying a CSI Driver • Create a “CSI volume driver” container that implements the volume plugin behavior and exposes a gRPC interface via a unix domain socket, as defined in the CSI spec (including Controller, Node, and Identity services). • Bundle the “CSI volume driver” container with helper containers (external-attacher, external-provisioner, node-driver-registrar, cluster-driver-registrar, external-resizer, external-snapshotter, livenessprobe) • These helper containers will assist the “CSI volume driver” container in interacting with the Kubernetes system. • Deploy the above as DaemonSets, StatefulSets to enable the storage provider in your Kubernetes Cluster.

Slide 11

Slide 11 text

Sample: NFS Driver

Slide 12

Slide 12 text

References & Examples • Understanding the Container Storage Interface (CSI) : https://medium.com/google-cloud/understanding-the-container-storage-interface-csi-ddbeb966a3b • Container Storage Interface: Present and Future - Jie Yu, Mesosphere, Inc: https://kccnceu18.sched.com/event/Dqvo/container-storage-interface-present-and-future-jie-yu-mesosph ere-inc-intermediate-skill-level-slides-attached • Using Container Storage Interface (CSI) in IBM Cloud Private: https://medium.com/ibm-cloud/using-csi-in-ibm-cloud-private-5212d6bf2ae3 • CSI Design Doc: https://github.com/kubernetes/community/blob/master/contributors/design-proposals/storage/container- storage-interface.md#cluster-level-deployment • CSI Git Repo: https://github.com/kubernetes-csi • Example CSI Drivers: https://github.com/kubernetes-csi/drivers

Slide 13

Slide 13 text

Conclusion • In this talk we learnt the following: • Need and Importance of CSI • Design Considerations for Plugin • Architecture, Components • Packaging & Deploying a CSI Driver • References & Examples

Slide 14

Slide 14 text

Questions & Answers