0

I am trying to associate a storage container with an IoT Hub but am having trouble doing so. The goal here is to connect a storage container in order to enable File Uploading in the IoT Hub.

I've followed the documentation here

you must first link an Azure Storage account to the IoT Hub. You can complete this task either through the Azure portal, or programmatically through the IoT Hub resource provider REST APIs.

but when working through the above flow, no storage containers are found. I do indeed have multiple storage contains on this account.

Any advice on how I can attach a storage container?

iammatthew2
  • 639
  • 2
  • 7
  • 20
  • 1
    Are the containers blob container in your storage account ? And have you checked the location of the storage account is the same with the IoT Hub and the containers are available? – Michael Xu Sep 05 '18 at 03:27
  • @MichaelXu-MSFT, that was the problem - my IoT Hub is in `US West` and my storage accounts were in `US West 2`. – iammatthew2 Sep 05 '18 at 13:10
  • I will change the comment as an answer so that it could help some other who will encounter the similar issue. – Michael Xu Sep 06 '18 at 01:18

2 Answers2

2

I think it is due to the location of your storage account. Please check the location of storage account is the same with the location of IoT Hub.If the location is different, you will not set the container in File Upload.

Michael Xu
  • 4,382
  • 1
  • 8
  • 16
  • your comment helped a lot. I could not view the storage account in the 'Azure SQL' because the two services (storage account, Azure SQL) were not in the same location (ex: East US) – Adel Mourad May 05 '23 at 18:03
0

Note: Before you upload a file to IoT Hub from a device, you must configure your hub by associating an Azure Storage account to it.

Steps to configure your hubs with Azure Storage:

CHEEKATLAPRADEEP
  • 12,191
  • 1
  • 19
  • 42