简体   繁体   中英

Azure databricks cluster don't have acces to mounted adls2

I followed the documentation azure-datalake-gen2-sp-access and I mounted a ADLS2 storage in databricks, but when I try to see data from the GUI I get the next error:

Cluster easy-matches-cluster-001 does not have the proper credentials to view the content. Please select another cluster.

在此处输入图像描述

I don't find any documentation, only something about premium databricks, so I can only access with a premium databricks resource?

Edit1: I can see the mounted storage with dbutils.

在此处输入图像描述

After mounting the storage account, please do run this command do check if you have data access permissions to the mount point created.

dbutils.fs.ls("/mnt/<mount-point>")
  • If you have data access - you will see the files inside the storage account.
  • Incase if you don't have data access- you will get this error - "This request is not authorized to perform this operation using this permissions", 403.

If you are able to mount the storage but unable to access, check if the ADLS2 account has the necessary roles assigned.

在此处输入图像描述

I was able to repro the same. Since you are using Azure Active Directory application, you would have to assign " Storage Blob Data Contributor " role to Azure Active Directory application too.

Below are steps for granting blob data contributor role on the registered application

1. Select your ADLS account. Navigate to Access Control (IAM). Select Add role assignment .

在此处输入图像描述

2. Select the role Storage Blob Data Contributor , Search and select your registered Azure Active Directory application and assign.

Back in Access Control (IAM) tab, search for your AAD app and check access.

在此处输入图像描述

3. Run dbutils.fs.ls("/mnt/<mount-point>") to confirm access.

在此处输入图像描述

在此处输入图像描述

Solved unmounting, mounting and restarting the cluster. I followed this doc: https://docs.microsoft.com/en-us/azure/databricks/kb/dbfs/remount-storage-after-rotate-access-key

If you still encounter the same issue when Access Control is checked. Do the following.

  1. Use dbutils.fs.unmount() to unmount all storage accounts.
  2. Restart the cluster.
  3. Remount

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM