az iot dps linked-hub

Manage linked IoT Hubs in an Azure IoT Hub Device Provisioning Service instance.

Commands

az iot dps linked-hub create

Create a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub delete

Update a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub list

List all linked IoT hubs in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub show

Show details of a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub update

Update a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub create

Create a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub create --dps-name
                             [--allocation-weight]
                             [--apply-allocation-policy {false, true}]
                             [--connection-string]
                             [--hn]
                             [--hrg]
                             [--location]
                             [--no-wait]
                             [--resource-group]

Examples

Create a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance

az iot dps linked-hub create --dps-name MyDps --resource-group MyResourceGroup --connection-string "HostName=test.azure-devices.net;SharedAccessKeyName=iothubowner;SharedAccessKey=XNBhoasdfhqRlgGnasdfhivtshcwh4bJwe7c0RIGuWsirW0=" --location westus

Create a linked IoT hub in an Azure IoT Hub Device Provisioning Service which applies allocation weight and weight being 10

az iot dps linked-hub create --dps-name MyDps --resource-group MyResourceGroup --connection-string "HostName=test.azure-devices.net;SharedAccessKeyName=iothubowner;SharedAccessKey=XNBhoasdfhqRlgGnasdfhivtshcwh4bJwe7c0RIGuWsirW0=" --location westus --allocation-weight 10 --apply-allocation-policy True

Required Parameters

--dps-name

IoT Hub Device Provisioning Service name.

Optional Parameters

--allocation-weight

Allocation weight of the IoT hub.

--apply-allocation-policy

A boolean indicating whether to apply allocation policy to the IoT hub.

accepted values: false, true
--connection-string

Connection string of the IoT hub. Required if hub name is not provided using --hub-name.

--hn --hub-name

IoT Hub name.

--hrg --hub-resource-group

IoT Hub resource group name.

--location -l

Location of the IoT hub.

--no-wait

Do not wait for the long-running operation to finish.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

az iot dps linked-hub delete

Update a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub delete --dps-name
                             --linked-hub
                             [--no-wait]
                             [--resource-group]

Examples

Delete linked IoT hub 'MyLinkedHub' in an Azure IoT Hub Device Provisioning Service instance

az iot dps linked-hub delete --dps-name MyDps --resource-group MyResourceGroup --linked-hub MyLinkedHub

Required Parameters

--dps-name

IoT Hub Device Provisioning Service name.

--linked-hub

Host name of linked IoT Hub.

Optional Parameters

--no-wait

Do not wait for the long-running operation to finish.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

az iot dps linked-hub list

List all linked IoT hubs in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub list --dps-name
                           [--resource-group]

Examples

List all linked IoT hubs in MyDps

az iot dps linked-hub list --dps-name MyDps --resource-group MyResourceGroup

Required Parameters

--dps-name

IoT Hub Device Provisioning Service name.

Optional Parameters

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

az iot dps linked-hub show

Show details of a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub show --dps-name
                           --linked-hub
                           [--resource-group]

Examples

Show details of linked IoT hub 'MyLinkedHub' in an Azure IoT Hub Device Provisioning Service

az iot dps linked-hub show --dps-name MyDps --resource-group MyResourceGroup --linked-hub MyLinkedHub

Required Parameters

--dps-name

IoT Hub Device Provisioning Service name.

--linked-hub

Host name of linked IoT Hub.

Optional Parameters

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.

az iot dps linked-hub update

Update a linked IoT hub in an Azure IoT Hub Device Provisioning Service instance.

az iot dps linked-hub update --dps-name
                             --linked-hub
                             [--allocation-weight]
                             [--apply-allocation-policy {false, true}]
                             [--no-wait]
                             [--resource-group]

Examples

Update linked IoT hub 'MyLinkedHub.azure-devices.net' in an Azure IoT Hub Device Provisioning Service

az iot dps linked-hub update --dps-name MyDps --resource-group MyResourceGroup --linked-hub MyLinkedHub.azure-devices.net --allocation-weight 10 --apply-allocation-policy True

Required Parameters

--dps-name

IoT Hub Device Provisioning Service name.

--linked-hub

Host name of linked IoT Hub.

Optional Parameters

--allocation-weight

Allocation weight of the IoT hub.

--apply-allocation-policy

A boolean indicating whether to apply allocation policy to the Iot hub.

accepted values: false, true
--no-wait

Do not wait for the long-running operation to finish.

--resource-group -g

Name of resource group. You can configure the default group using az configure --defaults group=<name>.