New-AzIotHub
Erstellt einen neuen IotHub.
Syntax
New-AzIotHub
-ResourceGroupName <String>
-Name <String>
-SkuName <PSIotHubSku>
-Units <Int64>
-Location <String>
[-Properties <PSIotHubInputProperties>]
[-Tag <Hashtable>]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Beschreibung
Erstellt einen neuen IotHub. Sie können iotHub entweder mit den Standardeigenschaften erstellen oder die Eingabeeigenschaften angeben.
Beispiele
Beispiel 1 Erstellen eines neuen IotHub mit Standardeigenschaften
$tags = @{}
$tags.Add('key1','value1')
New-AzIotHub -ResourceGroupName "myresourcegroup" -Name "myiothub" -SkuName "S1" -Units 1 -Location "northeurope" -Tag $tags
Erstellt einen neuen IotHub namens "myiothub" der sku "S1", Kapazität 1 und Standort "northeurope" im Lieferumfang von Tags.
Beispiel 2 Erstellen eines neuen IotHub mit dem MaxDeliveryCount der CloudToDevice-Warteschlange, die auf 20 festgelegt ist
New-AzIotHub -ResourceGroupName "myresourcegroup" -Name "myiothub" -SkuName "S1" -Units 1 -Location "northeurope" -Properties $properties
Erstellt einen neuen IotHub namens "myiothub" der sku "S1", Kapazität 1 und Standort "northeurope" mit erweiterten Eingabeeigenschaften, die durch $properties dargestellt werden. $psCloudToDeviceProperties = New-Object Microsoft.Azure.Commands.Management.IotHub.Models.PSCloudToDeviceProperties -Property @{MaxDeliveryCount=20} $properties = New-Object Microsoft.Azure.Commands.Management.IotHub.Models.PSIotHubInputProperties -Property @{CloudToDevice=$psCloudToDeviceProperties} New-AzIotHub -ResourceGroupName "myresourcegroup" -Name "myiothub" -SkuName "S1" -Units 1 -Location "northeurope" -Properties $properties
Parameter
-Confirm
Hiermit werden Sie vor der Ausführung des Cmdlets zur Bestätigung aufgefordert.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DefaultProfile
Anmeldeinformationen, Konto, Mandant und Abonnement für die Kommunikation mit Azure
Type: | IAzureContextContainer |
Aliases: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Location
Speicherort, an dem der IoT-Hub erstellt werden muss.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Name
Name des IotHub
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Properties
Eigenschaften des IoT-Hubs.
Type: | PSIotHubInputProperties |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ResourceGroupName
Ressourcengruppenname
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-SkuName
Name der Sku
Type: | PSIotHubSku |
Accepted values: | F1, S1, S2, S3, B1, B2, B3 |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Tag
IoT-Hubinstanztags. Eigenschaftenbehälter in Schlüssel-Wert-Paaren in Form einer Hashtabelle.
Type: | Hashtable |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Units
Anzahl der Einheiten
Type: | Int64 |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-WhatIf
Zeigt, was geschieht, wenn das Cmdlet ausgeführt wird. Das Cmdlet wird nicht ausgeführt.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Eingaben
Ausgaben
Azure PowerShell
Feedback
https://aka.ms/ContentUserFeedback.
Bald verfügbar: Im Laufe des Jahres 2024 werden wir GitHub-Issues stufenweise als Feedbackmechanismus für Inhalte abbauen und durch ein neues Feedbacksystem ersetzen. Weitere Informationen finden Sie unterFeedback senden und anzeigen für