New-​Azure​Rm​HD​Insight​Cluster

Creates an Azure HDInsight cluster in the specified resource group for the current subscription.

Syntax

New-AzureRmHDInsightCluster
   [-Location] <String>
   [-ResourceGroupName] <String>
   [-ClusterName] <String>
   [-ClusterSizeInNodes] <Int32>
   [-HttpCredential] <PSCredential>
   [[-DefaultStorageAccountName] <String>]
   [[-DefaultStorageAccountKey] <String>]
   [-AadTenantId <Guid>]
   [-AdditionalStorageAccounts <System.Collections.Generic.Dictionary`2[System.String,System.String]>]
   [-CertificateFileContents <Byte[]>]
   [-CertificatePassword <String>]
   [-ClusterTier <Tier>]
   [-ClusterType <String>]
   [-ComponentVersion <System.Collections.Generic.Dictionary`2[System.String,System.String]>]
   [-Config <AzureHDInsightConfig>]
   [-Configurations <System.Collections.Generic.Dictionary`2[System.String,System.Collections.Generic.Dictionary`2[System.String,System.String]]>]
   [-DefaultStorageAccountType <StorageType>]
   [-DefaultStorageContainer <String>]
   [-DefaultStorageRootPath <String>]
   [-EdgeNodeSize <String>]
   [-HeadNodeSize <String>]
   [-HiveMetastore <AzureHDInsightMetastore>]
   [-ObjectId <Guid>]
   [-OozieMetastore <AzureHDInsightMetastore>]
   [-OSType <OSType>]
   [-RdpAccessExpiry <DateTime>]
   [-RdpCredential <PSCredential>]
   [-ScriptActions <System.Collections.Generic.Dictionary`2[Microsoft.Azure.Management.HDInsight.Models.ClusterNodeType,System.Collections.Generic.List`1[Microsoft.Azure.Commands.HDInsight.Models.Management.AzureHDInsightScriptAction]]>]
   [-SecurityProfile <AzureHDInsightSecurityProfile>]
   [-SshCredential <PSCredential>]
   [-SshPublicKey <String>]
   [-SubnetName <String>]
   [-Version <String>]
   [-VirtualNetworkId <String>]
   [-WorkerNodeSize <String>]
   [-ZookeeperNodeSize <String>]
   [<CommonParameters>]
New-AzureRmHDInsightCluster
   [-Location] <String>
   [-ResourceGroupName] <String>
   [-ClusterName] <String>
   [-ClusterSizeInNodes] <Int32>
   [-HttpCredential] <PSCredential>
   [[-DefaultStorageAccountName] <String>]
   [[-DefaultStorageAccountKey] <String>]
   [-AadTenantId <Guid>]
   [-AdditionalStorageAccounts <System.Collections.Generic.Dictionary`2[System.String,System.String]>]
   [-CertificateFilePath <String>]
   [-CertificatePassword <String>]
   [-ClusterTier <Tier>]
   [-ClusterType <String>]
   [-ComponentVersion <System.Collections.Generic.Dictionary`2[System.String,System.String]>]
   [-Config <AzureHDInsightConfig>]
   [-Configurations <System.Collections.Generic.Dictionary`2[System.String,System.Collections.Generic.Dictionary`2[System.String,System.String]]>]
   [-DefaultStorageAccountType <StorageType>]
   [-DefaultStorageContainer <String>]
   [-DefaultStorageRootPath <String>]
   [-EdgeNodeSize <String>]
   [-HeadNodeSize <String>]
   [-HiveMetastore <AzureHDInsightMetastore>]
   [-ObjectId <Guid>]
   [-OozieMetastore <AzureHDInsightMetastore>]
   [-OSType <OSType>]
   [-RdpAccessExpiry <DateTime>]
   [-RdpCredential <PSCredential>]
   [-ScriptActions <System.Collections.Generic.Dictionary`2[Microsoft.Azure.Management.HDInsight.Models.ClusterNodeType,System.Collections.Generic.List`1[Microsoft.Azure.Commands.HDInsight.Models.Management.AzureHDInsightScriptAction]]>]
   [-SecurityProfile <AzureHDInsightSecurityProfile>]
   [-SshCredential <PSCredential>]
   [-SshPublicKey <String>]
   [-SubnetName <String>]
   [-Version <String>]
   [-VirtualNetworkId <String>]
   [-WorkerNodeSize <String>]
   [-ZookeeperNodeSize <String>]
   [<CommonParameters>]

Description

The New-AzureHDInsightCluster creates an Azure HDInsight cluster by using the specified parameters or by using a configuration object that is created by using the New-AzureRmHDInsightClusterConfig cmdlet.

Examples

-------------------------- Example 1: Create an Azure HDInsight cluster --------------------------

@{paragraph=PS C:\>}

PS C:\> # Primary storage account info
        $storageAccountResourceGroupName = "Group"
        $storageAccountName = "yourstorageacct001"
        $storageAccountKey = Get-AzureStorageAccountKey `
            -ResourceGroupName $storageAccountResourceGroupName `
            -Name $storageAccountName | %{ $_.Key1 }
        $storageContainer = "container002"

        # Cluster configuration info
        $location = "East US 2"
        $clusterResourceGroupName = "Group"
        $clusterName = "your-hadoop-002"
        $clusterCreds = Get-Credential

        # If the cluster's resource group doesn't exist yet, run:
        #   New-AzureRMResourceGroup -Name $clusterResourceGroupName -Location $location

        # Create the cluster
        New-AzureRmHDInsightCluster `
            -ClusterType Hadoop `
            -OSType Windows `
            -ClusterSizeInNodes 4 `
            -ResourceGroupName $clusterResourceGroupName `
            -ClusterName $clusterName `
            -HttpCredential $clusterCreds `
            -Location $location `
            -DefaultStorageAccountName "$storageAccountName.blob.core.contoso.net" `
            -DefaultStorageAccountKey $storageAccountKey `
            -DefaultStorageContainer $storageContainer

This command creates a cluster in the current subscription.

Required Parameters

-ClusterName

Specifies the name of the cluster.

Type:String
Position:2
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ClusterSizeInNodes

Specifies the number of Worker nodes for the cluster.

Type:Int32
Position:3
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-HttpCredential

Specifies the cluster login (HTTP) credentials for the cluster.

Type:PSCredential
Position:4
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Location

Specifies the location for the cluster.

Type:String
Position:0
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ResourceGroupName

Specifies the name of the resource group.

Type:String
Position:1
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Optional Parameters

-AadTenantId

Specifies the Azure AD Tenant ID that will be used when accessing Azure Data Lake Store.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-AdditionalStorageAccounts

Specifies the additional Azure Storage accounts for the cluster. You can alternatively use the Add-AzureRmHDInsightStorage cmdlet.

Type:System.Collections.Generic.Dictionary`2[System.String,System.String]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CertificateFileContents

Specifies file contents of the certificate that will be used when accessing Azure Data Lake Store.

Type:Byte[]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CertificateFilePath

Specifies the file path to the certificate that will be used to authenticate as the Service Principal. The cluster will use this when accessing Azure Data Lake Store.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CertificatePassword

Specifies the password for the certificate that will be used to authenticate as the Service Principal. The cluster will use this when accessing Azure Data Lake Store.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ClusterTier

Specifies the HDInsight cluster tier. By default, this is Standard. The Premium tier can only be used with Linux clusters, and it enables the use of some new features.

Type:Tier
Parameter Sets:Standard, Premium
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ClusterType

Specifies the type of cluster to create. Options are: Hadoop, HBase, Storm, Spark

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ComponentVersion
Type:System.Collections.Generic.Dictionary`2[System.String,System.String]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Config

Specifies the cluster object to be used to create the cluster. This object can be created by using the New-AzureRmHDInsightClusterConfig cmdlet.

Type:AzureHDInsightConfig
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Configurations

Specifies the configurations of this HDInsight cluster. You can alternatively use the Add-AzureRmHDInsightConfigValues cmdlet.

Type:System.Collections.Generic.Dictionary`2[System.String,System.Collections.Generic.Dictionary`2[System.String,System.String]]
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DefaultStorageAccountKey

Specifies the account key for the default Azure Storage account that the HDInsight cluster will use. You can alternatively use the Set-AzureRmHDInsightDefaultStorage cmdlet.

Type:String
Position:6
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DefaultStorageAccountName

Specifies the name of the default Azure Storage account that the HDInsight cluster will use. You can alternatively use the Set-AzureRmHDInsightDefaultStorage cmdlet.

Type:String
Position:5
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DefaultStorageAccountType

Specifies the type of the default storage account that the HDInsight cluster will use. Possible values are AzureStorage and AzureDataLakeStore. Defaults to AzureStorage if not specified.

Type:StorageType
Parameter Sets:AzureStorage, AzureDataLakeStore
Position:Named
Default value:AzureStorage
Accept pipeline input:False
Accept wildcard characters:False
-DefaultStorageContainer

Specifies the name of the default container in the default Azure storage account that the HDInsight cluster will use. You can alternatively use the Set-AzureRmHDInsightDefaultStorage cmdlet.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DefaultStorageRootPath

Specifies the path-prefix in the Data Lake Store Account that the HDInsight cluster will use as the default filesystem.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-EdgeNodeSize

Specifies the size of the virtual machine for the edge node. Use Get-AzureRmVMSize for acceptable VM sizes, and see HDInsight's pricing page. This parameter is valid only for RServer clusters.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-HeadNodeSize

Specifies the size of the virtual machine for the Head node. Use Get-AzureRmVMSize for acceptable VM sizes, and see HDInsight's pricing page.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-HiveMetastore

Specifies the SQL Database to store Hive metadata. You can alternatively use the Add-AzureRmHDInsightMetastore cmdlet.

Type:AzureHDInsightMetastore
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OSType

Specifies the operating system for the cluster. Options are: Windows, Linux

Type:OSType
Parameter Sets:Windows, Linux
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ObjectId

Specifies the Azure AD object ID (a GUID) of the Azure AD Service Principal that represents the cluster. The cluster will use this when accessing Azure Data Lake Store.

Type:Guid
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OozieMetastore

Specifies the SQL Database to store Oozie metadata. You can alternatively use the Add-AzureRmHDInsightMetastore cmdlet.

Type:AzureHDInsightMetastore
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RdpAccessExpiry

Specifies the expiration, as a DateTime object, for Remote Desktop Protocol (RDP) access to a cluster.

Type:DateTime
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RdpCredential

Specifies the Remote Desktop (RDP) credentials for the cluster. This is only for Windows clusters.

Type:PSCredential
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ScriptActions

Specifies the script actions to run on the cluster at the end of cluster creation. You can alternatively use Add-AzureRmHDInsightScriptAction.

Type:System.Collections.Generic.Dictionary`2[Microsoft.Azure.Management.HDInsight.Models.ClusterNodeType,System.Collections.Generic.List`1[Microsoft.Azure.Commands.HDInsight.Models.Management.AzureHDInsightScriptAction]]
Parameter Sets:HeadNode, WorkerNode, ZookeeperNode, EdgeNode
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-SecurityProfile

Specifies the security related properties used to create a secure cluster. You can alternatively use the Add-AzureRmHDInsightSecurityProfile cmdlet.

Type:AzureHDInsightSecurityProfile
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-SshCredential

Specifies the SSH credential to be used for SSH connections. This is only for Linux clusters.

Type:PSCredential
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-SshPublicKey

Specifies the public key to be used for SSH connections. This is only for Linux clusters.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-SubnetName

Specifies the name of a subnet within the chosen virtual network for the cluster.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Version

Specifies the HDI version of the HDInsight cluster.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VirtualNetworkId

Specifies the ID of the virtual network into which to provision the cluster.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WorkerNodeSize

Specifies the size of the virtual machine for the Worker node. Use Get-AzureRmVMSize for acceptable VM sizes, and see HDInsight's pricing page.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ZookeeperNodeSize

Specifies the size of the virtual machine for the Zookeeper node. Use Get-AzureRmVMSize for acceptable VM sizes, and see HDInsight's pricing page. This parameter is valid only for HBase or Storm clusters.

Type:String
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Notes

Keywords: azure, azurerm, arm, resource, management, manager, hadoop, hdinsight, hd, insight