Yarn Commands


 
yarn applicationattempt
 Syntax
yarn application
   [-list [<-appStates States>] [<-appTypes Types>] ]
   [-status ApplicationId]
   [-kill ApplicationId]

ü  yarn cluster

      The yarn classpath command prints the class path needed to access the Hadoop jar and the required libraries.
Syntax
yarn classpath

yarn daemonlog
Gets or sets the log level for each daemon.
Syntax
yarn daemonlog
[-getlevel <host:port> <name>] | [-setlevel <host:port> <name> <level>]
Parameters
Parameter
Description
-getlevel <host:port> <name>
Prints the log level of the daemon running at <host:port>. This command internally connects to http://<host:port>/logLevel?log=<name>.
-setlevel <host:port> <name> <level>
Sets the log level of the daemon running at <host:port>. This command internally connects to http://<host:port>/logLevel?log=<name>.

yarn debugcontrol
used to save additional DEBUG logs for scheduling in YARN to a separate file without restarting the RM.
The logs are saved in /opt/mapr/Hadoop/Hadoop<version>/logs/yarn-mapr-scheduling-debug.log
Syntax
yarn debugcontrol
[-addapp <application_name>] | [-addqueue <queue_name> ]| [-removeapp <application_name> ] | [-removequeue <queue_name> ] | [-getapps ] | [-getqueues ]
Parameters
Parameter
Description
-addapp <application_name>
enables additional scheduling DEBUG on the application
-addqueue <queue_name>
enables additional scheduling DEBUG on the queue
-removeapp <application_name>
disable addition scheduling DEBUG on the application
-removequeue <queue_name>
disable addition scheduling DEBUG on the queue
-getapps
lists the applications with additional scheduling DEBUG
-getqueues
lists the queues with additional scheduling DEBUG

yarn node
Prints node report(s)
Syntax
yarn node
     [-list [-states <States>] | [-all]]
     [-status NodeId]
Parameters
Parameter
Description
-list [-states <states>] | [-all]]
Lists all running nodes. Optionally, filter nodes based on state or choose to list all the nodes.
  • Use -states <states> to filter nodes based on a comma-separate list of node states.
  • Use -all to list all nodes.
-status NodeId
Prints the status report of the node.
yarn logs
Dumps the YARN container logs.
Syntax
yarn logs -applicationID <application ID>
     [-appowner <AppOwner>]
     [-containerId <ContainerID>]
     [-nodeAddress <NodeAddress>]
Parameters
Parameter
Description
-applicationID
Specifies an application Id.
-appowner <AppOwner>
Specifies the application owner. This defaults to the current user if this option is not specified.
-containerID <ContainerId>
Specifies the container ID. This is required when -nodeAddress is specified.
-nodeAddress <NodeAddress>
Specifies the node address in the following format: nodename:port This is required when -containerID is specified.
yarn queue
Prints queue information
Syntax
yarn queue -status <queue name>
Parameters
The following command parameter is supported for yarn queue:
Parameter
Description
status
The queue name.
yarn rmadmin
Runs the ResourceManager admin client.
Syntax
yarn rmadmin
    [-refreshQueues]
    [-refreshNodes]
    [-refreshUserToGroupsMapping]
    [-refreshSuperUserGroupsConfiguration]
    [-refreshAdminAcls]
    [-refreshServiceAcl]
    [-getGroups <username>]
    [-help <cmd>]
    [-transitionToActive <serviceId>]
    [-transitionToStandby <serviceId>]
    [-getServiceState <serviceId>]
    [-checkHealth <serviceId>]
Parameters
Parameter
Description
-refreshQueues
Reloads the queues' acls, states, and scheduler specific properties. The ResourceManager reloads the mapred-queues configuration file.
-refreshNodes
Refreshes the host information at the ResourceManager.
-refreshUserToGroupsMappings
Refreshes user-to-groups mappings.
-refreshSuperUserGroupsConfiguration
Refreshes superuser proxy groups mappings.
-refreshAdminAcls
Refreshes acls for administration of ResourceManager.
-refreshServiceAcl
Reloads the service-level authorization policy file. The ResourceManager reloads the authorization policy file.
-getGroups <username>
Gets the groups that the user belongs to.
-help <cmd>
Displays help for the given parameter or all parameters if no parameter is specified.
-transitionToActive <serviceId>
Transitions the service into the Active state. You can use this parameter when the ResourceManager is configured to failover manually.
-transitionToStandby <serviceId>
Transitions the service into Standby state. You can use this parameter when the ResourceManager is configured to failover manually.
-getServiceState <serviceId>
Returns the service state. You can use this parameter when the ResourceManager is configured to failover manually or automatically but not with the zero configuration failover option.
-checkHealth <serviceId>
Requests a health check for the service. If the health check fails, the RMAdmin tool exits with a non-zero exit code. You can use this parameter when the ResourceManager is configured to failover manually or automatically but not with the zero configuration failover option.
yarn version
Prints the YARN version.
Syntax
yarn version
Output
$ yarn version
Hadoop 2.7.0-mapr-1808
 Subversion git@github.com:mapr/private-hadoop-common.git -r 286a35acc6daf3276ade21a51619dba30c0d5357
 Compiled by root on 2018-09-25T16:36Z
 Compiled with protoc 2.5.0
 From source with checksum f5eb7427d39f2e91e9f4a63c0a1d259
 This command was run using /opt/mapr/hadoop/hadoop-2.7.0/share/hadoop/common/hadoop-common-2.7.0-mapr-1808.jar
yarn jar
Runs a jar file that contains YARN code.
Syntax
yarn jar <jar> [<mainClass>] [<arguments>]
Parameters
The following commands parameters are supported for yarn jar:
Parameter
Description
<jar>
The JAR file.
<mainClass>
Sets the applications entry point.
<arguments>
Arguments to the program specified in the JAR file.

Comments

Popular posts from this blog

General information about Netezza : Default Error details

Minus in Teradata?...