Description
When CSI migration is enabled and the external-provisioner provisions an in-tree PV, it files wrong pv.kubernetes.io/provisioned-by
annotation. As result, when the CSI migration is disabled later, such PVs can be deleted only by the external-provisioner. They should be deleted by the in-tree one.
-
Enable CSI migration (OpenStack Cinder used below).
-
Create StorageClass for in-tree volume plugin
provisioner: kubernetes.io/cinder
-
Create PVC with this StorageClass
-
Check that the external-provisioner created in-tree PV (with
cinder
), but with a wrongprovisioned-by
:apiVersion: v1 kind: PersistentVolume metadata: annotations: pv.kubernetes.io/provisioned-by: cinder.csi.openstack.org name: pvc-6d2b1fb9-324c-4350-926f-639ff087eaaa spec: cinder: fsType: ext4 volumeID: 49921926-4dd7-4d17-b32d-742cff332a2f
-
Disable the CSI migration.
-
Delete the PVC.
Actual result: The PV is deleted by the CSI driver.
Expected result: The PV is deleted by in-tree volume plugin. The CSI driver may not be installed at that time.
Metadata
Metadata
Assignees
Labels
No labels