Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-48748

[control-plane-operator] azure-file-csi using nfs protocal provision volume failed of "vnetName or location is empty"

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • 4.18, 4.19
    • HyperShift / ARO
    • None
    • Important
    • None
    • Proposed
    • False
    • Hide

      None

      Show
      None
    • Release Note Not Required
    • In Progress

      This is a clone of issue OCPBUGS-48708. The following is the description of the original issue:

      Description of problem:

      [control-plane-operator] azure-file-csi using nfs protocal provision volume failed of "vnetName or location is empty"    

      Version-Release number of selected component (if applicable):

      4.18.0-0.nightly-2025-01-21-070749    

      How reproducible:

      Always    

      Steps to Reproduce:

          1. Create aro hosted cluster on azure.
          2. Create a new storageclass using azure file csi provisioner and nfs protocol and create pvc with the created storageclass, create pod comsume the pvc.
      
      $ oc apply -f - <<EOF
      allowVolumeExpansion: true
      apiVersion: storage.k8s.io/v1
      kind: StorageClass
      metadata:
        name: azurefile-csi-nfs
      parameters:
        protocol: nfs
      provisioner: file.csi.azure.com
      reclaimPolicy: Delete
      volumeBindingMode: Immediate
      ---
      kind: PersistentVolumeClaim
      apiVersion: v1
      metadata:
        name: mypvc
      spec:
        accessModes:
          - ReadWriteOnce
        resources:
          requests:
            storage: 1Gi
        storageClassName: azurefile-csi-nfs
        volumeMode: Filesystem
      ---
      apiVersion: v1
      kind: Pod
      metadata:
        name: mypod
      spec:
        containers:
          - name: hello-app
            image: quay.io/openshifttest/hello-openshift@sha256:56c354e7885051b6bb4263f9faa58b2c292d44790599b7dde0e49e7c466cf339
            volumeMounts:
              - mountPath: /mnt/storage
                name: data
        volumes:
          - name: data
            persistentVolumeClaim:
              claimName: mypvc
      EOF
      
           3. Check the volume should be provisioned and pod could read and write inside the file volume.
          

      Actual results:

        In step 3: the volume provision failed of vnetName or location is empty
      $  oc describe pvc mypvc
      Name:          mypvc
      Namespace:     default
      StorageClass:  azurefile-csi-nfs
      Status:        Pending
      Volume:
      Labels:        <none>
      Annotations:   volume.beta.kubernetes.io/storage-provisioner: file.csi.azure.com
                     volume.kubernetes.io/storage-provisioner: file.csi.azure.com
      Finalizers:    [kubernetes.io/pvc-protection]
      Capacity:
      Access Modes:
      VolumeMode:    Filesystem
      Used By:       mypod
      Events:
        Type     Reason                Age               From                                                                                                       Message
        ----     ------                ----              ----                                                                                                       -------
        Normal   ExternalProvisioning  7s (x3 over 10s)  persistentvolume-controller                                                                                Waiting for a volume to be created either by the external provisioner 'file.csi.azure.com' or manually by the system administrator. If volume creation is delayed, please verify that the provisioner is running and correctly registered.
        Normal   Provisioning          3s (x4 over 10s)  file.csi.azure.com_azure-file-csi-driver-controller-7cb9b5f788-n9ztr_85399802-95c4-468e-814d-2c4df5140069  External provisioner is provisioning volume for claim "default/mypvc"
        Warning  ProvisioningFailed    3s (x4 over 10s)  file.csi.azure.com_azure-file-csi-driver-controller-7cb9b5f788-n9ztr_85399802-95c4-468e-814d-2c4df5140069  failed to provision volume with StorageClass "azurefile-csi-nfs": rpc error: code = Internal desc = update service endpoints failed with error: vnetName or location is empty  

      Expected results:

          In step 3: the volume should be provisioned and pod could read and write inside the file volume. 

      Additional info:

       # aro hcp missed the vnetName/vnetResourceGroup will caused using nfs protocol provision volumes failed
      oc extract secret/azure-file-csi-config --to=-
      # cloud.conf
      {
        "cloud": "AzurePublicCloud",
        "tenantId": "XXXXXXXXXX",
        "useManagedIdentityExtension": false,
        "subscriptionId": "XXXXXXXXXX",
        "aadClientId": "XXXXXXXXXX",
        "aadClientSecret": "",
        "aadClientCertPath": "/mnt/certs/ci-op-gcprj1wl-0a358-azure-file",
        "resourceGroup": "ci-op-gcprj1wl-0a358-rg",
        "location": "centralus",
        "vnetName": "",
        "vnetResourceGroup": "",
        "subnetName": "",
        "securityGroupName": "",
        "securityGroupResourceGroup": "",
        "routeTableName": "",
        "cloudProviderBackoff": false,
        "cloudProviderBackoffDuration": 0,
        "useInstanceMetadata": false,
        "loadBalancerSku": "",
        "disableOutboundSNAT": false,
        "loadBalancerName": ""
      }
         

              rh-ee-brcox Bryan Cox
              openshift-crt-jira-prow OpenShift Prow Bot
              He Liu He Liu
              Penghao Wang
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated: