Skip to content

Commit aa5d46f

Browse files
committed
Added 'update iot hub' and moved resource creation to prereqs
1 parent a7ae3c7 commit aa5d46f

File tree

4 files changed

+51
-27
lines changed

4 files changed

+51
-27
lines changed

articles/iot-hub/iot-hub-create-through-portal.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,17 @@ This article describes how to create and manage IoT hubs using the [Azure portal
2020

2121
[!INCLUDE [iot-hub-include-create-hub](../../includes/iot-hub-include-create-hub.md)]
2222

23-
## Change the settings of the IoT hub
23+
## Update the IoT hub
2424

25-
You can change the settings of an existing IoT hub after it's created from the IoT Hub pane. Here are some of the properties you can set for an IoT hub:
25+
You can change the settings of an existing IoT hub after it's created from the IoT Hub pane. Here are some properties you can set for an IoT hub:
2626

27-
**Pricing and scale**: You can use this property to migrate to a different tier or set the number of IoT Hub units.
27+
**Pricing and scale**: Migrate to a different tier or set the number of IoT Hub units.
2828

2929
**IP Filter**: Specify a range of IP addresses that will be accepted or rejected by the IoT hub.
3030

31-
**Properties**: Provides the list of properties that you can copy and use elsewhere, such as the resource ID, resource group, location, and so on.
31+
**Properties**: A list of properties that you can copy and use elsewhere, such as the resource ID, resource group, location, and so on.
32+
33+
For a complete list of options to update an IoT hub, see the [**az iot hub update** commands](/cli/azure/iot/hub#az-iot-hub-update) reference page.
3234

3335
### Shared access policies
3436

articles/iot-hub/iot-hub-create-use-iot-toolkit.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@ This article shows you how to use the [Azure IoT Tools for Visual Studio Code](h
2121

2222
- [Visual Studio Code](https://code.visualstudio.com/)
2323

24-
- [Azure IoT Tools](https://marketplace.visualstudio.com/items?itemName=vsciot-vscode.azure-iot-tools) installed for Visual Studio Code.
24+
- [Azure IoT Tools](https://marketplace.visualstudio.com/items?itemName=vsciot-vscode.azure-iot-tools) installed for Visual Studio Code
25+
26+
- An Azure resource group: [create a resource group](/azure/azure-resource-manager/management/manage-resource-groups-portal#create-resource-groups) in the Azure portal
2527

2628
## Create an IoT hub without an IoT Project
2729

articles/iot-hub/iot-hub-create-using-cli.md

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,7 @@ This article shows you how to create an IoT hub using Azure CLI.
1717

1818
[!INCLUDE [azure-cli-prepare-your-environment.md](../../includes/azure-cli-prepare-your-environment.md)]
1919

20-
## Create an IoT Hub
21-
22-
Use the Azure CLI to create a resource group and then add an IoT hub.
23-
24-
1. When you create an IoT hub, you must create it in a resource group. Either use an existing resource group, or run the following [command to create a resource group](/cli/azure/resource):
20+
When you create an IoT hub, you must create it in a resource group. Either use an existing resource group, or run the following [command to create a resource group](/cli/azure/resource):
2521

2622
```azurecli-interactive
2723
az group create --name {your resource group name} --location westus
@@ -33,9 +29,12 @@ Use the Azure CLI to create a resource group and then add an IoT hub.
3329
> ```azurecli-interactive
3430
> az account list-locations -o table
3531
> ```
36-
>
3732
38-
2. Run the following [command to create an IoT hub](/cli/azure/iot/hub#az-iot-hub-create) in your resource group, using a globally unique name for your IoT hub:
33+
## Create an IoT Hub
34+
35+
Use the Azure CLI to create a resource group and then add an IoT hub.
36+
37+
Run the following [command to create an IoT hub](/cli/azure/iot/hub#az-iot-hub-create) in your resource group, using a globally unique name for your IoT hub:
3938
4039
```azurecli-interactive
4140
az iot hub create --name {your iot hub name} \
@@ -47,7 +46,19 @@ Use the Azure CLI to create a resource group and then add an IoT hub.
4746

4847
The previous command creates an IoT hub in the S1 pricing tier for which you're billed. For more information, see [Azure IoT Hub pricing](https://azure.microsoft.com/pricing/details/iot-hub/).
4948

50-
For more information on Azure IoT Hub commands, see the [`az iot hub`](/cli/azure/iot/hub?view=azure-cli-latest&preserve-view=true) reference article.
49+
For more information on Azure IoT Hub commands, see the [`az iot hub`](/cli/azure/iot/hub) reference article.
50+
51+
## Update the IoT hub
52+
53+
You can change the settings of an existing IoT hub after it's created. Here are some properties you can set for an IoT hub:
54+
55+
**Pricing and scale**: Migrate to a different tier or set the number of IoT Hub units.
56+
57+
**IP Filter**: Specify a range of IP addresses that will be accepted or rejected by the IoT hub.
58+
59+
**Properties**: A list of properties that you can copy and use elsewhere, such as the resource ID, resource group, location, and so on.
60+
61+
For a complete list of options to update an IoT hub, see the [**az iot hub update** commands](/cli/azure/iot/hub#az-iot-hub-update) reference page.
5162

5263
## Register a new device in the IoT hub
5364

articles/iot-hub/iot-hub-create-using-powershell.md

Lines changed: 23 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,24 @@ ms.custom: devx-track-azurepowershell
1414

1515
[!INCLUDE [iot-hub-resource-manager-selector](../../includes/iot-hub-resource-manager-selector.md)]
1616

17-
## Introduction
18-
1917
You can use Azure PowerShell cmdlets to create and manage Azure IoT hubs. This tutorial shows you how to create an IoT hub with PowerShell.
2018

21-
2219
[!INCLUDE [updated-for-az](../../includes/updated-for-az.md)]
2320

2421
Alternatively, you can use Azure Cloud Shell, if you'd rather not install additional modules onto your machine. The following section gets you started with Azure Cloud Shell.
2522

2623
[!INCLUDE [cloud-shell-try-it.md](../../includes/cloud-shell-try-it.md)]
2724

25+
## Prerequisites
26+
27+
You need a resource group to deploy an IoT hub. You can use an existing resource group or create a new one.
28+
29+
To create a new resource group for your IoT hub, use the [New-AzResourceGroup](/powershell/module/az.Resources/New-azResourceGroup) command. This example creates a resource group called **MyIoTRG1** in the **East US** region:
30+
31+
```azurepowershell-interactive
32+
New-AzResourceGroup -Name MyIoTRG1 -Location "East US"
33+
```
34+
2835
## Connect to your Azure subscription
2936

3037
If you're using Cloud Shell, you're already logged in to your subscription, so you can skip this section. If you're running PowerShell locally instead, enter the following command to sign in to your Azure subscription:
@@ -34,19 +41,9 @@ If you're using Cloud Shell, you're already logged in to your subscription, so y
3441
Login-AzAccount
3542
```
3643

37-
## Create a resource group
38-
39-
You need a resource group to deploy an IoT hub. You can use an existing resource group or create a new one.
40-
41-
To create a resource group for your IoT hub, use the [New-AzResourceGroup](/powershell/module/az.Resources/New-azResourceGroup) command. This example creates a resource group called **MyIoTRG1** in the **East US** region:
42-
43-
```azurepowershell-interactive
44-
New-AzResourceGroup -Name MyIoTRG1 -Location "East US"
45-
```
46-
4744
## Create an IoT hub
4845

49-
To create an IoT hub in the resource group you created in the previous step, use the [New-AzIotHub](/powershell/module/az.IotHub/New-azIotHub) command. This example creates an **S1** hub called **MyTestIoTHub** in the **East US** region:
46+
Create an IoT hub, using your resource group,. Use the [New-AzIotHub](/powershell/module/az.IotHub/New-azIotHub) command. This example creates an **S1** hub called **MyTestIoTHub** in the **East US** region:
5047

5148
```azurepowershell-interactive
5249
New-AzIotHub `
@@ -76,6 +73,18 @@ Remove-AzIotHub `
7673
-Name MyTestIoTHub
7774
```
7875

76+
## Update the IoT hub
77+
78+
You can change the settings of an existing IoT hub after it's created. Here are some properties you can set for an IoT hub:
79+
80+
**Pricing and scale**: Migrate to a different tier or set the number of IoT Hub units.
81+
82+
**IP Filter**: Specify a range of IP addresses that will be accepted or rejected by the IoT hub.
83+
84+
**Properties**: A list of properties that you can copy and use elsewhere, such as the resource ID, resource group, location, and so on.
85+
86+
Explore the [**Set-AzIotHub** commands](/powershell/module/az.iothub/set-aziothub) for a complete list of update options.
87+
7988
## Next steps
8089

8190
Now that you've deployed an IoT hub using a PowerShell cmdlet, explore more articles:

0 commit comments

Comments
 (0)