New-​Azure​Rm​HD​Insight​Map​Reduce​Job​Definition

Creates a MapReduce job object.

Syntax

New-AzureRmHDInsightMapReduceJobDefinition
   [-Arguments <String[]>]
   [-Files <String[]>]
   [-StatusFolder <String>]
   -ClassName <String>
   [-Defines <Hashtable>]
   -JarFile <String>
   [-JobName <String>]
   [-LibJars <String[]>]
   [-InformationAction <ActionPreference>]
   [-InformationVariable <String>]
   [<CommonParameters>]

Description

The New-AzureRmHDInsightMapReduceJobDefinition cmdlet defines a new MapReduce job for use with an Azure HDInsight cluster.

Examples

Example 1: Create a MapReduce job definition

PS C:\># Cluster info
PS C:\>$clusterName = "your-hadoop-001"
PS C:\>$clusterCreds = Get-Credential

PS C:\>New-AzureRmHDInsightMapReduceJobDefinition -StatusFolder $statusFolder `
            -ClassName $className `
            -JarFile $jarFilePath `
        | Start-AzureRmHDInsightJob `
            -ClusterName $clusterName `
            -ClusterCredential $clusterCreds

This command creates a MapReduce job definition.

Required Parameters

-ClassName

Specifies the job class in the JAR file.

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

Specifies the JAR file to use for the job.

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

Optional Parameters

-Arguments

Specifies an array of arguments for the job. The arguments are passed as command-line arguments to each task.

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

Specifies Hadoop configuration values to set for when the job runs.

Type:Hashtable
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Files

Specifies a collection of files that are associated with a Hive job.

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

Specifies how this cmdlet responds to an information event.The acceptable values for this parameter are:- Continue

  • Ignore
  • Inquire
  • SilentlyContinue
  • Stop
  • Suspend
Type:ActionPreference
Aliases:infa
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-InformationVariable

Specifies an information variable.

Type:String
Aliases:iv
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobName

Specifies the name of the job.

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

Specifies the lib JARS for the job.

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

Specifies the location of the folder that contains standard outputs and error outputs for a job.

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