Add-AzHDInsightComponentVersion
Dodaje wersję usługi uruchomionej w klastrze do obiektu konfiguracji klastra.
Składnia
Add-AzHDInsightComponentVersion
[-Config] <AzureHDInsightConfig>
[-ComponentName] <String>
[-ComponentVersion] <String>
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Opis
Polecenie cmdlet Add-AzHDInsightComponentVersion dodaje wersję usługi uruchomionej w klastrze do obiektu konfiguracji usługi Azure HDInsight utworzonego przez polecenie cmdlet New-AzHDInsightClusterConfig.
Przykłady
# Primary storage account info
$storageAccountResourceGroupName = "Group"
$storageAccountName = "yourstorageacct001"
$storageAccountResourceId = "yourstorageaccountresourceid"
$storageAccountKey = Get-AzStorageAccountKey `
-ResourceGroupName $storageAccountResourceGroupName `
-Name $storageAccountName | ForEach-Object{ $_.Key1 }
$storageContainer = "container001"
# Cluster configuration info
$location = "East US 2"
$clusterResourceGroupName = "Group"
$clusterName = "your-spark-001"
$clusterCreds = Get-Credential
$sshClusterCreds = Get-Credential
# If the cluster's resource group doesn't exist yet, run:
# New-AzResourceGroup -Name $clusterResourceGroupName -Location $location
# Create the cluster
New-AzHDInsightClusterConfig `
| Add-AzHDInsightComponentVersion `
-ComponentName "Spark" `
-ComponentVersion "2.0" `
| New-AzHDInsightCluster `
-ClusterType Spark `
-OSType Linux `
-ClusterSizeInNodes 4 `
-ResourceGroupName $clusterResourceGroupName `
-ClusterName $clusterName `
-HttpCredential $clusterCreds `
-Location $location `
-StorageAccountResourceId $storageAccountResourceId `
-StorageAccountKey $storageAccountKey `
-StorageContainer $storageContainer `
-SshCredential $sshCredentials `
-Version "3.5"
To polecenie dodaje wersję platformy Spark do klastra usługi HDInsight o nazwie "your-spark-001".
Parametry
-ComponentName
Typ: String
Position: 1
Domyślna wartość: None
Wymagane: True
Akceptowanie danych wejściowych potoku: False
Akceptowanie symboli wieloznacznych: False
-ComponentVersion
Typ: String
Position: 2
Domyślna wartość: None
Wymagane: True
Akceptowanie danych wejściowych potoku: False
Akceptowanie symboli wieloznacznych: False
-Config
Typ: AzureHDInsightConfig
Position: 0
Domyślna wartość: None
Wymagane: True
Akceptowanie danych wejściowych potoku: True
Akceptowanie symboli wieloznacznych: False
-Confirm
Prosi o potwierdzenie przed uruchomieniem cmdletu.
Typ: SwitchParameter
Aliasy: cf
Position: Named
Domyślna wartość: None
Wymagane: False
Akceptowanie danych wejściowych potoku: False
Akceptowanie symboli wieloznacznych: False
-DefaultProfile
Poświadczenia, konto, dzierżawa i subskrypcja używane do komunikacji z platformą Azure
Typ: IAzureContextContainer
Aliasy: AzContext, AzureRmContext, AzureCredential
Position: Named
Domyślna wartość: None
Wymagane: False
Akceptowanie danych wejściowych potoku: False
Akceptowanie symboli wieloznacznych: False
-WhatIf
Typ: SwitchParameter
Aliasy: wi
Position: Named
Domyślna wartość: None
Wymagane: False
Akceptowanie danych wejściowych potoku: False
Akceptowanie symboli wieloznacznych: False
Dane wyjściowe