Unable to use persistent volume mounts Azure Kubernetes

Severin Hersche 0 Zuverlässigkeitspunkte
2025-02-26T19:17:14.63+00:00

I try to bind a volume to rabbit mq

volumes:
      - name: rabbitmq-data
        persistentVolumeClaim:
          claimName: rabbitmq-pvc-new

        volumeMounts:
        - name: rabbitmq-data
          mountPath: /var/lib/rabbitmq
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: rabbitmq-pvc-new 
spec:
  accessModes:
  - ReadWriteOnce
  storageClassName: managed-csi  
  resources:
    requests:
      storage: 1Gi 

On Azure I see that the pvc is bound: Benutzerbild

One important thing: my node is only running in Zone 2. This may be the reason, but I'm not sure.

The pod stays in a ContainerCreating state. With this message:

Normal Scheduled 65s default-scheduler Successfully assigned default/rabbitmq to aks-agentpool

Normal SuccessfulAttachVolume 51s attachdetach-controller AttachVolume.Attach succeeded for volume "pvc-01"

Warning FailedMount 11s (x7 over 50s) kubelet MountVolume.MountDevice failed for volume "pvc-01" : rpc error: code = Internal desc = failed to find disk on lun 0. azureDisk - findDiskByLun(0) failed with error(failed to find disk by lun 0)

Microsoft Q&A
Microsoft Q&A
Verwenden Sie dieses Tag, um Vorschläge, gewünschte Features und Fehler mit dem Microsoft Q&A-Team zu teilen. Das Microsoft Q&A-Team wertet Ihr Feedback regelmäßig aus und stellt Updates zur Verfügung.
200 Fragen
0 Kommentare Keine Kommentare
{count} Stimmen

Ihre Antwort

Fragesteller*innen können Antworten als akzeptierte Antworten markiert werden, wodurch Benutzer*innen wissen, dass diese Antwort das Problem gelöst hat.