hadoop2.0.x【3】--Yarn Commands

Overview

Yarn commands are invoked by the bin/yarn script. Running the yarn script without any arguments prints the description for all commands.

Yarn的命令以bin/yarn的形式进行脚本调用。不带任何参数运行yarn脚本会打印所有命令的描述。

Usage: yarn [--config confdir] COMMAND

Yarn has an option parsing framework that employs parsing generic options as well as running classes.

Yarn有一个选项解析框架用于解析一般的选项和运行类。

COMMAND_OPTIONSDescription
--config confdirOverwrites the default Configuration directory. Default is $HADOOP_PREFIX/conf.
覆盖缺省配置目录。默认值是$ HADOOP_PREFIX/ conf。
COMMAND COMMAND_OPTIONSVarious commands with their options are described in the following sections. The commands have been grouped into User Commands and Administration Commands.
不同的命令在下面的章节中描述。这些命令被分为用户命令和管理员命令。

User Commands

Commands useful for users of a Hadoop cluster.

用于hadoop集群命令

jar

Runs a jar file. Users can bundle their Yarn code in a jar file and execute it using this command.

运行jar文件。用户可以打包他们yarn代码在一个jar文件,然后使用这个命令执行。

  Usage: yarn jar <jar> [mainClass] args...
application

Prints application(s) report/kill application

打印应用程序的报告/杀掉应用程序

  Usage: yarn application <options>
COMMAND_OPTIONSDescription
-status ApplicationIdSpecify an application id
指定程序id
-listLists all the Applications from RM
从RM列出所有程序的列表
-kill ApplicationIdSpecify an application id
指定要杀程序的id
node

Prints node report(s)

打印节点信息

  Usage: yarn node <options>
COMMAND_OPTIONSDescription
-status NodeIdSpecify a node id
指定节点id
-listLists all the Nodes
列出节点列表
logs

Dump the container logs

转存容器日志

  Usage: yarn logs <options>
COMMAND_OPTIONSDescription
-applicationId ApplicationIdSpecify an application id
指定程序id
-appOwner AppOwnerSpecify an application owner
指定程序拥有者
-containerId ContainerIdSpecify a container id
指定容器id
-nodeAddress NodeAddressSpecify a node address
指定节点地址
classpath

Prints the class path needed to get the Hadoop jar and the required libraries

打印需要的hadoop jar和其他所需要库的jar所在路径

  Usage: yarn classpath
version

Prints the version.

打印版本

  Usage: yarn version

Administration Commands

Commands useful for administrators of a Hadoop cluster.

用于hadoop集群管理员命令

resourcemanager

Start the ResourceManager

启动资源管理器

  Usage: yarn resourcemanager
nodemanager

Start the NodeManager

启动节点管理器

  Usage: yarn nodemanager
proxyserver

Start the web proxy server

开启web代理服务

  Usage: yarn proxyserver
rmadmin

Runs ResourceManager admin client

  Usage: yarn rmadmin [-refreshQueues] [-refreshNodes] [-refreshUserToGroupsMapping] 
                      [-refreshSuperUserGroupsConfiguration] [-refreshAdminAcls] 
                      [-refreshServiceAcl] [-help [cmd]]
COMMAND_OPTIONSDescription
-refreshQueuesReload the queues' acls, states and scheduler specific properties. ResourceManager will reload the mapred-queues configuration file.
重新载入队列的ACL,状态和调度程序特定的属性。ResourceManager将刷新mapred-队列的配置文件。
-refreshNodesRefresh the hosts information at the ResourceManager.
刷新在ResourceManager中的主机信息。
-refreshUserToGroupsMappingsRefresh user-to-groups mappings.
刷新用户到组的映射。
-refreshSuperUserGroupsConfigurationRefresh superuser proxy groups mappings.
刷新超级用户代理组的映射。
-refreshAdminAclsRefresh acls for administration of ResourceManager
刷新的ACL的ResourceManager的管理
-refreshServiceAclReload the service-level authorization policy file ResoureceManager will reload the authorization policy file.
刷新服务级授权策略文件ResoureceManager将重新加载授权策略文件。
-help [cmd]Displays help for the given command or all commands if none is specified.
显示帮助对于给定的命令或所有命令,如果没有指定。
daemonlog

Get/Set the log level for each daemon.

设置/获取每一个守护集成的日志等级

设置日志的守护进程层次

  Usage: yarn daemonlog -getlevel <host:port> <name> 
  Usage: yarn daemonlog -setlevel <host:port> <name> <level>
COMMAND_OPTIONSDescription
-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

打印在主机上运行的守护进程的日志级别:端口。该命令在内部连接到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

设置在主机上运行的守护进程的日志级别:端口。该命令在内部连接到http://host:port/logLevel?log=name

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值