azuredisk-csi-driver icon indicating copy to clipboard operation
azuredisk-csi-driver copied to clipboard

Azure Disk CSI Driver

Azure Disk CSI driver for Kubernetes

Travis Coverage Status FOSSA Status

About

This driver allows Kubernetes to use Azure Disk volume, csi plugin name: disk.csi.azure.com

Project status

V1: GA

V2: Preview

Container Images & Kubernetes Compatibility

V1

Driver Version Image supported k8s version
master branch mcr.microsoft.com/k8s/csi/azuredisk-csi:latest 1.21+
v1.22.0 mcr.microsoft.com/oss/kubernetes-csi/azuredisk-csi:v1.22.0 1.21+
v1.21.0 mcr.microsoft.com/oss/kubernetes-csi/azuredisk-csi:v1.21.0 1.20+
v1.20.0 mcr.microsoft.com/oss/kubernetes-csi/azuredisk-csi:v1.20.0 1.20+

V2

Driver Version Image supported k8s version
main_v2 branch 1.21+
v2.0.0-beta.6 mcr.microsoft.com/oss/kubernetes-csi/azuredisk-csi:v2.0.0-beta.6 1.21+

Driver parameters

Please refer to disk.csi.azure.com driver parameters

storage class disk.csi.azure.com parameters are compatible with built-in azuredisk plugin

Set up CSI driver on AKS cluster (only for AKS users)

follow guide here

Prerequisite

  • The driver depends on cloud provider config file, usually it's /etc/kubernetes/azure.json on agent nodes deployed by AKS or aks-engine, here is azure.json example.
    specify a different cloud provider config filecreate azure-cred-file configmap before driver installation, e.g. for OpenShift, it's /etc/kubernetes/cloud.conf (make sure config file path is in the volumeMounts.mountPath)
    kubectl create configmap azure-cred-file --from-literal=path="/etc/kubernetes/cloud.conf" --from-literal=path-windows="C:\\k\\cloud.conf" -n kube-system
  • This driver also supports read cloud config from kubernetes secret as first priority
  • Make sure identity used by driver has Contributor role on node resource group
    • When installing side-by-side with an earlier version of the driver on an AKS cluster, ensure the agentpool service principal or managed service identity is assigned to the Contributor role on the resource groups used to store managed disks.
  • Set up CSI driver on Azure RedHat OpenShift(ARO)

Install driver on a Kubernetes cluster

  • install via kubectl on public Azure (please use helm for Azure Stack, RedHat/CentOS)
  • install via helm charts on public Azure, Azure Stack, RedHat/CentOS

Install Azure Disk CSI Driver V2 on a Kubernetes cluster (Preview)

  • install via helm charts

Examples

  • Basic usage

Features

  • Topology (Availability Zone)
    • ZRS disk support
  • Snapshot
  • Volume Cloning
  • Volume Expansion
  • Raw Block Volume
  • Windows
  • Shared Disk
  • Volume Limits
  • fsGroupPolicy
  • Tune disk performance on Linux

New in V2

  • Attachments Replicas for Faster Pod Failover (Preview)
    • See pod failover demo for example configuration.
  • Advanced disk performance tuning (Preview)

Troubleshooting

  • CSI driver troubleshooting guide

Support

  • Please see our support policy

Limitations

  • Please refer to Azure Disk CSI Driver Limitations

Kubernetes Development

  • Please refer to development guide

View CI Results

Links