Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
smoqt
Advocate I
Advocate I

Mounting Azure Blob Storage Container using Fabric Notebook (PySpark)

I'm attempting to mount an Azure Blob Storage Container within a Fabric Notebook as suggested here.

 

I am setup as a Storage Blob Data Contributor on the container (which I have seen suggested).

 

The code:

 

from notebookutils import mssparkutils  

accountKey = mssparkutils.credentials.getSecret("<vaultURI>", "<secretName>")
mssparkutils.fs.mount(  
    "abfss://<mycontainer>@<accountname>.dfs.core.windows.net",  
    "/test",  
    {"accountKey":accountKey}
)

 

 

I get an error: "Mount failed with operationId <operationId>, get detail from /var/log/blobfuse/blobfusev2.log"

 

When checking the log, I notice the following sequence:

 

|2024-02-28T17:44:15.982905+00:00 vm-65b06715 blobfusev2[2878]: Testing authetication to /<some-guid>/test/ ...

|2024-02-28T17:44:16.036071+00:00 vm-65b06715 blobfusev2[2878]: Unknown failure: [json.exception.type_error.302] type must be string, but is number

|2024-02-28T17:44:16.036174+00:00 vm-65b06715 blobfusev2[2878]: Failed to connect to the storage container. There might be something wrong about the storage config, please double check the storage account name, account key/sas token/OAuth access token and container name. errno=1600

 

Naturally, I have double-checked the accountname and key as well as tried other methods like using a sas token.  So far, I'm have no success mounting anything (I also tried mounting a lakehouse but it just times out with no errors in the log).  Am I missing something?

4 REPLIES 4
smoqt
Advocate I
Advocate I

As a test, I created two new containers within the same storage account and was able to mount both.  I've tried mounting other, pre-existing containers but none have mounted successfully.

 

Both were empty containers.  I then unmounted one of the containers, added an empty txt file to the container, tried mounting it again but got the error.

 

Next, I deleted the file, tried once more and it mounted successfully.

raaph
Regular Visitor

I have the same issue: In a notebook in Synapse I can not mount a container that has files inside, but it works if the container is empty. I mount it with 'linkedService' and not 'accountKey' like smoqt.

Anonymous
Not applicable

Hi @smoqt 
Thanks for using Fabric Community. 
Can you please provide the livy id/driver log or cluster id /session id for the above error?

Anonymous
Not applicable

Hi @egons11 

We haven’t heard from you on the last response and was just checking back to see if you can provide the details asked above. We will definitely try to help.
Thanks

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Fabric Update Carousel

Fabric Monthly Update - October 2025

Check out the October 2025 Fabric update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.