How to mount a file share in the kubernetes cluster as we are facing issues while trying to mount using aad pod identity?

Salim, Mondu 0 Reputation points
2024-07-05T05:42:50.9366667+00:00

MountVolume.MountDevice failed for volume "fileatp-pv" : rpc error: code = Internal desc = volume(nosaprivchatpdev01#uploads) mount //nosaprivchatpdev01.file.core.windows.net/uploads on /var/lib/kubelet/plugins/kubernetes.io/csi/file.csi.azure.com/6fba9cc36eebf7e1450760b850a68bc9dc57970b07873c2b57fdd3b3eb3df44e/globalmount failed with mount failed: exit status 32 Mounting command: mount Mounting arguments: -t cifs -o dir_mode=0777,file_mode=0777,sec=ntlmssp,nosharesock,actimeo=30,mfsymlinks,<masked> //nosaprivchatpdev01.file.core.windows.net/uploads /var/lib/kubelet/plugins/kubernetes.io/csi/file.csi.azure.com/6fba9cc36eebf7e1450760b850a68bc9dc57970b07873c2b57fdd3b3eb3df44e/globalmount Output: mount error(13): Permission denied Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg) Please refer to http://aka.ms/filemounterror for possible causes and solutions for mount errors.

Azure Kubernetes Service (AKS)
Azure Kubernetes Service (AKS)
An Azure service that provides serverless Kubernetes, an integrated continuous integration and continuous delivery experience, and enterprise-grade security and governance.
1,996 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. deherman-MSFT 35,636 Reputation points Microsoft Employee
    2024-07-05T18:16:10.2466667+00:00

    @Salim, Mondu

    Ther permission denied error seems to indicate an issue with either the account access key or configuration of the storage account. Please check the prerequisites are fulfilled:

    • Your AKS cluster Control plane identity (that is, your AKS cluster name) is added to the Contributor role on the VNet and NetworkSecurityGroup.
    • Your AKS cluster's service principal or managed service identity (MSI) must be added to the Contributor role to the storage account.

    Please make sure that you have the settings for the storage account need to be adjusted to allow access. If possible, you can try creating a new storage account and file share following these directions.

    Hope this helps! Let me know if you are still facing issues and I will be happy to assist.


    If you still have questions, please let us know in the "comments" and we would be happy to help you. Comment is the fastest way of notifying the experts.

    If the answer has been helpful, we appreciate hearing from you and would love to help others who may have the same question. Accepting answers helps increase visibility of this question for other members of the Microsoft Q&A community.

    Thank you for helping to improve Microsoft Q&A!

    User's image

    0 comments No comments