[ Go Back ]
Yarn commands are invoked by the bin/yarn script. Running the yarn script without any arguments prints the description for all commands.
Usage: yarn [--config confdir] COMMAND
Yarn has an option parsing framework that employs parsing generic options as well as running classes.
COMMAND_OPTIONS | Description |
---|---|
--config confdir | Overwrites the default Configuration directory. Default is $HADOOP_PREFIX/conf. |
COMMAND COMMAND_OPTIONS | Various commands with their options are described in the following sections. The commands have been grouped into User Commands and Administration Commands. |
Commands useful for users of a Hadoop cluster.
Runs a jar file. Users can bundle their Yarn code in a jar file and execute it using this command.
Usage: yarn jar <jar> [mainClass] args...
Prints application(s) report/kill application
Usage: yarn application <options>
COMMAND_OPTIONS | Description |
---|---|
-status ApplicationId | Specify an application id |
-list | Lists all the Applications from RM |
-kill ApplicationId | Specify an application id |
Prints node report(s)
Usage: yarn node <options>
COMMAND_OPTIONS | Description |
---|---|
-status NodeId | Specify a node id |
-list | Lists all the Nodes |
Dump the container logs
Usage: yarn logs <options>
COMMAND_OPTIONS | Description |
---|---|
-applicationId ApplicationId | Specify an application id |
-appOwner AppOwner | Specify an application owner |
-containerId ContainerId | Specify a container id |
-nodeAddress NodeAddress | Specify a node address |
Commands useful for administrators of a Hadoop cluster.
Runs ResourceManager admin client
Usage: yarn rmadmin [-refreshQueues] [-refreshNodes] [-refreshUserToGroupsMapping] [-refreshSuperUserGroupsConfiguration] [-refreshAdminAcls] [-refreshServiceAcl] [-help [cmd]]
COMMAND_OPTIONS | Description |
---|---|
-refreshQueues | Reload the queues' acls, states and scheduler specific properties. ResourceManager will reload the mapred-queues configuration file. |
-refreshNodes | Refresh the hosts information at the ResourceManager. |
-refreshUserToGroupsMappings | Refresh user-to-groups mappings. |
-refreshSuperUserGroupsConfiguration | Refresh superuser proxy groups mappings. |
-refreshAdminAcls | Refresh acls for administration of ResourceManager |
-refreshServiceAcl | Reload the service-level authorization policy file ResoureceManager will reload the authorization policy file. |
-help [cmd] | Displays help for the given command or all commands if none is specified. |
Get/Set the log level for each daemon.
Usage: yarn daemonlog -getlevel <host:port> <name> Usage: yarn daemonlog -setlevel <host:port> <name> <level>
COMMAND_OPTIONS | 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 |