azurefile-csi-driver
azurefile-csi-driver copied to clipboard
New(?) restrictions regarding secret naming (error message "could not get account name from <actual-secret-name>, correct format: azure-storage-account-(.+)-secret" in kube-controller-manager logs)
Hi,
we recently switched to AKS versions which deprecated resp. removed the old in-tree AzureFile provisioner and are now using the azurefile-csi-driver. We now noticed that the kube-controller-manager logs are filled with messages of this form
could not get account name from <actual-secret-name>, correct format: azure-storage-account-(.+)-secret
where
The PersistentVolume "foobar" is invalid: spec.persistentvolumesource: Forbidden: spec.persistentvolumesource is im
mutable after creation
core.PersistentVolumeSource{
... // 11 identical fields
FC: nil,
Flocker: nil,
AzureFile: &core.AzureFilePersistentVolumeSource{
- SecretName: "azure-storage-account-hei07opei-secret",
+ SecretName: "our-old-secret-name-here",
Aside from some clarification regarding the urgency of fixing this for existing clusters, I wonder why this requirement regarding the secret name came into being - after all, the storage account name can be found in the secret itself. So maybe someone can shed some light on the need for this naming convention.
THX J
this error message is actually a warning message in TranslateInTreePVToCSI: could not get account name from <actual-secret-name>, correct format: azure-storage-account-(.+)-secret which is used to get volumeID with an account name. if you have set secret name correctly, the azure file driver could get account name from secret directly.
And you are using in-tree AzureFile PV, I would suggest using Azure File CSI driver PV directly.