Permalink
Fetching contributors…
Cannot retrieve contributors at this time
113 lines (72 sloc) 6.29 KB
title description services author ms.reviewer ms.service ms.custom ms.topic ms.date ms.author
Create Hadoop clusters using PowerShell - Azure HDInsight
Learn how to create Hadoop, HBase, Storm, or Spark clusters on Linux for HDInsight by using Azure PowerShell.
hdinsight
jasonwhowell
jasonh
hdinsight
hdinsightactive
conceptual
02/21/2018
jasonh

Create Linux-based clusters in HDInsight using Azure PowerShell

[!INCLUDE selector]

Azure PowerShell is a powerful scripting environment that you can use to control and automate the deployment and management of your workloads in Microsoft Azure. This document provides information about how to create a Linux-based HDInsight cluster by using Azure PowerShell. It also includes an example script.

[!NOTE] Azure PowerShell is only available on Windows clients. If you are using a Linux, Unix, or Mac OS X client, see Create a Linux-based HDInsight cluster using Azure Classic CLI for information about using the classic CLI to create a cluster.

Prerequisites

You must have the following before starting this procedure:

Create cluster

[!INCLUDE delete-cluster-warning]

To create an HDInsight cluster by using Azure PowerShell, you must complete the following procedures:

  • Create an Azure resource group
  • Create an Azure Storage account
  • Create an Azure Blob container
  • Create an HDInsight cluster

The following script demonstrates how to create a new cluster:

[!code-powershellmain]

The values you specify for the cluster login are used to create the Hadoop user account for the cluster. Use this account to connect to services hosted on the cluster such as web UIs or REST APIs.

The values you specify for the SSH user are used to create the SSH user for the cluster. Use this account to start a remote SSH session on the cluster and run jobs. For more information, see the Use SSH with HDInsight document.

[!IMPORTANT] If you plan to use more than 32 worker nodes (either at cluster creation or by scaling the cluster after creation), you must also specify a head node size with at least 8 cores and 14 GB of RAM.

For more information on node sizes and associated costs, see HDInsight pricing.

It can take up to 20 minutes to create a cluster.

Create cluster: Configuration object

You can also create an HDInsight configuration object using New-AzureRmHDInsightClusterConfig cmdlet. You can then modify this configuration object to enable additional configuration options for your cluster. Finally, use the -Config parameter of the New-AzureRmHDInsightCluster cmdlet to use the configuration.

The following script creates a configuration object to configure an R Server on HDInsight cluster type. The configuration enables an edge node, RStudio, and an additional storage account.

[!code-powershellmain]

[!WARNING] Using a storage account in a different location than the HDInsight cluster is not supported. When using this example, create the additional storage account in the same location as the server.

Customize clusters

Delete the cluster

[!INCLUDE delete-cluster-warning]

Troubleshoot

If you run into issues with creating HDInsight clusters, see access control requirements.

Next steps

Now that you have successfully created an HDInsight cluster, use the following resources to learn how to work with your cluster.

Hadoop clusters

HBase clusters

Storm clusters

Spark clusters