You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/iot-dps/how-to-provision-multitenant.md
+16-20Lines changed: 16 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
-
title: Tutorial - Provision devices for multitenancy in Azure IoT Hub Device Provisioning Service
3
-
description: This tutorial shows how to provision devices for multitenancy with your Device Provisioning Service (DPS) instance
2
+
title: Tutorial - Provision devices for geolatency in Azure IoT Hub Device Provisioning Service
3
+
description: This tutorial shows how to provision devices for geolocation with your Device Provisioning Service (DPS) instance
4
4
author: kgremban
5
5
ms.author: kgremban
6
6
ms.topic: tutorial
@@ -9,24 +9,20 @@ ms.service: iot-dps
9
9
services: iot-dps
10
10
---
11
11
12
-
# Tutorial: Provision for multitenancy
12
+
# Tutorial: Provision for geolatency
13
13
14
-
This tutorial shows how to securely provision multiple simulated symmetric key devices to a group of IoT Hubs using an [allocation policy](concepts-service.md#allocation-policy). Allocation policies that are defined by the provisioning service support a variety of allocation scenarios. Two common scenarios are:
14
+
This tutorial shows how to securely provision multiple simulated symmetric key devices to a group of IoT Hubs using an [allocation policy](concepts-service.md#allocation-policy). Allocation policies that are defined by the provisioning service support a variety of allocation scenarios.
15
15
16
-
***Geolocation / GeoLatency**: As a device moves between locations, network latency is improved by having the device provisioned to the IoT hub that's closest to each location. In this scenario, a group of IoT hubs, which span across regions, are selected for enrollments. The **Lowest latency** allocation policy is selected for these enrollments. This policy causes the Device Provisioning Service to evaluate device latency and determine the closet IoT hub out of the group of IoT hubs.
16
+
**Geolocation / GeoLatency**: is a common allocation scenario. As a device moves between locations, network latency is improved by having the device provisioned to the IoT hub that's closest to each location. In this scenario, a group of IoT hubs, which span across regions, are selected for enrollments. The **Lowest latency** allocation policy is selected for these enrollments. This policy causes the Device Provisioning Service to evaluate device latency and determine the closet IoT hub out of the group of IoT hubs.
17
17
18
-
***Multi-tenancy**: Devices used within an IoT solution may need to be assigned to a specific IoT hub or group of IoT hubs. The solution may require all devices for a particular tenant to communicate with a specific group of IoT hubs. In some cases, a tenant may own IoT hubs and require devices to be assigned to their IoT hubs.
19
-
20
-
It's common to combine these two scenarios. For example, a multitenant IoT solution commonly assigns tenant devices using a group of IoT hubs that are scattered across different regions. These tenant devices can be assigned to the IoT hub in the group that has the lowest latency based on geographic location.
21
-
22
-
This tutorial uses a simulated device sample from the [Azure IoT C SDK](https://github.com/Azure/azure-iot-sdk-c) to demonstrate how to provision devices in a multitenant scenario across regions. You will perform the following steps in this tutorial:
18
+
This tutorial uses a simulated device sample from the [Azure IoT C SDK](https://github.com/Azure/azure-iot-sdk-c) to demonstrate how to provision devices across regions. You'll perform the following steps in this tutorial:
23
19
24
20
> [!div class="checklist"]
25
21
> * Use the Azure CLI to create two regional IoT hubs (**West US 2** and **East US**)
26
-
> * Create a multitenant enrollment
22
+
> * Create an enrollment that provisions devices based on geolocation (lowest latency)
27
23
> * Use the Azure CLI to create two regional Linux VMs to act as devices in the same regions (**West US 2** and **East US**)
28
24
> * Set up the development environment for the Azure IoT C SDK on both Linux VMs
29
-
> * Simulate the devices to see that they are provisioned for the same tenant in the closest region.
25
+
> * Simulate the devices and verify that they're provisioned to the IoT hub in the closest region.
30
26
31
27
>[!IMPORTANT]
32
28
> Some regions may, from time to time, enforce restrictions on the creation of Virtual Machines. At the time of writing this guide, the *westus2* and *eastus* regions permitted the creation of VMs. If you're unable to create in either one of those regions, you can try a different region. To learn more about choosing Azure geographical regions when creating VMs, see [Regions for virtual machines in Azure](../virtual-machines/regions.md)
@@ -41,7 +37,7 @@ This tutorial uses a simulated device sample from the [Azure IoT C SDK](https://
41
37
42
38
## Create two regional IoT hubs
43
39
44
-
In this section, you'll create an Azure resource group, and two new regional IoT hub resources for a tenant. One IoT hub will be for the **West US 2** region and the other will be for the **East US** region.
40
+
In this section, you'll create an Azure resource group, and two new regional IoT hub resources. One IoT hub will be for the **West US 2** region and the other will be for the **East US** region.
45
41
46
42
>[!IMPORTANT]
47
43
>It's recommended that you use the same resource group for all resources created in this tutorial. This will make clean up easier after you are finished.
@@ -68,9 +64,9 @@ In this section, you'll create an Azure resource group, and two new regional IoT
68
64
69
65
This command may take a few minutes to complete.
70
66
71
-
## Create the multitenant enrollment
67
+
## Create an enrollment for geolatency
72
68
73
-
In this section, you'll create a new enrollment group for the tenant devices.
69
+
In this section, you'll create a new enrollment group for the your devices.
74
70
75
71
For simplicity, this tutorial uses [Symmetric key attestation](concepts-symmetric-key-attestation.md) with the enrollment. For a more secure solution, consider using [X.509 certificate attestation](concepts-x509-attestation.md) with a chain of trust.
76
72
@@ -92,7 +88,7 @@ For simplicity, this tutorial uses [Symmetric key attestation](concepts-symmetri
92
88
93
89
5. Select **Link a new IoT Hub**
94
90
95
-
:::image type="content" source="./media/how-to-provision-multitenant/create-multitenant-enrollment.png" alt-text="Add multitenant enrollment group for symmetric key attestation.":::
91
+
:::image type="content" source="./media/how-to-provision-multitenant/create-multitenant-enrollment.png" alt-text="Add enrollment group for symmetric key attestation and lowest latency.":::
96
92
97
93
6. On the **Add link to IoT hub** page, enter the following information:
98
94
@@ -122,7 +118,7 @@ For simplicity, this tutorial uses [Symmetric key attestation](concepts-symmetri
122
118
123
119
## Create regional Linux VMs
124
120
125
-
In this section, you'll create two regional Linux virtual machines (VMs). These VMs will run a device simulation sample from each region to demonstrate device provisioning for tenant devices from both regions.
121
+
In this section, you'll create two regional Linux virtual machines (VMs). These VMs will run a device simulation sample from each region to demonstrate device provisioning for devices from both regions.
126
122
127
123
To make clean-up easier, these VMs will be added to the same resource group that contains the IoT hubs that were created, *contoso-us-resource-group*. However, the VMs will run in separate regions (**West US 2** and **East US**).
128
124
@@ -194,7 +190,7 @@ To make clean-up easier, these VMs will be added to the same resource group that
194
190
195
191
## Prepare the Azure IoT C SDK development environment
196
192
197
-
In this section, you'll clone the Azure IoT C SDK on each VM. The SDK contains a sample that simulates a tenant's device provisioning from each region.
193
+
In this section, you'll clone the Azure IoT C SDK on each VM. The SDK contains a sample that simulates a device provisioning from each region.
198
194
199
195
For each VM:
200
196
@@ -279,7 +275,7 @@ For **both** *eastus* and *westus 2* devices:
279
275
p3w2DQr9WqEGBLUSlFi1jPQ7UWQL4siAGy75HFTFbf8=
280
276
```
281
277
282
-
3. Now each tenant device has their own derived device key and unique registration ID to perform symmetric key attestation with the enrollment group during the provisioning process.
278
+
3. Now each device has its own derived device key and unique registration ID to perform symmetric key attestation with the enrollment group during the provisioning process.
283
279
284
280
## Simulate the devices from each region
285
281
@@ -344,7 +340,7 @@ The sample code simulates a device boot sequence that sends the provisioning req
8. Once the build succeeds, run **prov\_dev\_client\_sample.exe** on both VMs to simulate a tenant device from each region. Notice that each device is allocated to the tenant IoT hub closest to the simulated device's regions.
343
+
8. Once the build succeeds, run **prov\_dev\_client\_sample.exe** on both VMs to simulate a device from each region. Notice that each device is allocated to the IoT hub closest to the simulated device's region.
0 commit comments