阅读目录

本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作。

文章是哥(mephisto)写的,SourceLink

  上一篇,我们对Hadoop命令中的HDFS Commands进行了简略的列举,下面我们就MapReduce Commands和Yarn Commands进行简略的列举,官网基本都是英文的,所以只能拙略的翻译下,妄大家见谅。

  下面,我们就开始对Hadoop命令下进行讲解。

MapReduce Commands

一:介绍

  所有的MapReduce命令通过bin/ mapred脚本调用。不指定参数运行mapred脚本会打印所有命令的描述。

  用法: mapred [SHELL_OPTIONS] COMMAND [GENERIC_OPTIONS] [COMMAND_OPTIONS]

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

COMMAND_OPTIONS Description
SHELL_OPTIONS The common set of shell options. These are documented on the Hadoop Commands Reference page.
GENERIC_OPTIONS The common set of options supported by multiple commands. See the Hadoop Commands Reference for more information.
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.

User Commands

一:介绍

  用于Hadoop集群用户命令。

二:archive

  创建一个Hadoop档案.More information can be found at Hadoop Archives Guide.

三:classpath

  打印Hadoop jar和所需的libs的class路径。

  用法: mapred classpath

四:distcp

  递归复制文件或目录. More information can be found at Hadoop DistCp Guide.

五:job

  MapReduce jobs的命令

  用法: mapred job | [GENERIC_OPTIONS] | [-submit <job-file>] | [-status <job-id>] | [-counter <job-id> <group-name> <counter-name>] | [-kill <job-id>] | [-events <job-id> <from-event-#> <#-of-events>] | [-history [all] <jobOutputDir>] | [-list [all]] | [-kill-task <task-id>] | [-fail-task <task-id>] | [-set-priority <job-id> <priority>]

六:pipes

  运行一个pipes job.

  用法: mapred pipes [-conf <path>] [-jobconf <key=value>, <key=value>, ...] [-input <path>] [-output <path>] [-jar <jar file>] [-inputformat <class>] [-map <class>] [-partitioner <class>] [-reduce <class>] [-writer <class>] [-program <executable>] [-reduces <num>]

七:queue

  查看作业队列信息

  用法:  mapred queue [-list] | [-info <job-queue-name> [-showJobs]] | [-showacls]

八:version

  打印版本。

  用法:  mapred version

Administration Commands

一:介绍

  用于Hadoop集群用户命令。

二:historyserver

    启动JobHistoryServer.

  用法: mapred historyserver

三:hsadmin

  运行一个MapReduce hsadmin客户端执行jobhistoryserver administrative命令。

  用法:Usage: mapred hsadmin [-refreshUserToGroupsMappings] | [-refreshSuperUserGroupsConfiguration] | [-refreshAdminAcls] | [-refreshLoadedJobCache] | [-refreshLogRetentionSettings] | [-refreshJobRetentionSettings] | [-getGroups [username]] | [-help [cmd]]

YARN Commands

一:介绍

  所有的YARN命令通过bin/yarn 脚本调用。不指定参数运行yarn脚本会打印所有命令的描述。

  用法: yarn [--config confdir] COMMAND [--loglevel loglevel] [GENERIC_OPTIONS] [COMMAND_OPTIONS]

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

User Commands

一:介绍

  用于Hadoop集群用户命令。

二:application

  打印app报表或kill掉app

  用法: yarn application [options]

三:applicationattempt

  打印applicationattempt(s) 报表

  用法: yarn applicationattempt [options]

四:classpath

  打印Hadoop jar和需要的库类路径。

  用法: yarn classpath

五:container

  打印container(s)报表

  用法: yarn container [options]

六:jar

  执行一个jar文件。

  用法: yarn jar <jar> [mainClass] args...

七:logs

  转储容器日志

  用法: yarn logs -applicationId <application ID> [options]

八:node

  打印node报表

  用法: yarn node [options]

九:queue

  打印queue信息

  用法: yarn queue [options]

十:version

  打印hadoop版本。

  用法: yarn version

Administration Commands用

一:介绍

  用于Hadoop集群用户命令。

二:daemonlog

  获取/设置在后台Log的级别

  用法:yarn daemonlog -getlevel <host:httpport> <classname>
       yarn daemonlog -setlevel <host:httpport> <classname> <level>

三:nodemanager

  启动NodeManager

  用法: yarn nodemanager

四:proxyserver

  启动web proxy server

  用法: yarn proxyserver

五:resourcemanager

  启动ResourceManager

  用法: yarn resourcemanager [-format-state-store]

六:rmadmin

  运行ResourceManager管理客户端

用法:yarn rmadmin [-refreshQueues]
               [-refreshNodes]
               [-refreshUserToGroupsMapping]
               [-refreshSuperUserGroupsConfiguration]
               [-refreshAdminAcls]
               [-refreshServiceAcl]
               [-getGroups [username]]
               [-transitionToActive [--forceactive] [--forcemanual] <serviceId>]
               [-transitionToStandby [--forcemanual] <serviceId>]
               [-failover [--forcefence] [--forceactive] <serviceId1> <serviceId2>]
               [-getServiceState <serviceId>]
               [-checkHealth <serviceId>]
               [-help [cmd]]

七:scmadmin

  运行Shared Cache Manager管理客户端

  用法: yarn scmadmin [options]

八:sharedcachemanager

  启动Shared Cache Manager

  用法: yarn sharedcachemanager

九:timelineserver

  启动TimeLineServer

  用法: yarn timelineserver

--------------------------------------------------------------------

  到此,本章节的内容讲述完毕。

引用

Apache  MapReduce Commands:http://hadoop.apache.org/docs/current/hadoop-mapreduce-client/hadoop-mapreduce-client-core/MapredCommands.html

Apache YARN Commands:http://hadoop.apache.org/docs/current/hadoop-yarn/hadoop-yarn-site/YarnCommands.html

Apache 1.04 中文:http://hadoop.apache.org/docs/r1.0.4/cn/commands_manual.html

系列索引

  【源】从零自学Hadoop系列索引

 

本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作。

文章是哥(mephisto)写的,SourceLink

从零自学Hadoop(13):Hadoop命令下的更多相关文章

  1. 从零自学Hadoop(17):Hive数据导入导出,集群数据迁移下

    阅读目录 序 将查询的结果写入文件系统 集群数据迁移一 集群数据迁移二 系列索引 本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作. 文章是哥(mephis ...

  2. 从零自学Hadoop(21):HBase数据模型相关操作下

    阅读目录 序 变量 数据模型操作 系列索引 本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作. 文章是哥(mephisto)写的,SourceLink 序 ...

  3. 从零自学Hadoop(04):Linux准备下

    阅读目录 序 搭建环境 系列索引 本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作. 文章是哥(mephisto)写的,SourceLink 序 我们已经准 ...

  4. 从零自学Hadoop(11):Hadoop命令上

    阅读目录 序 概述 Hadoop Common Commands User Commands Administration Commands File System Shell 引用 系列索引 本文版 ...

  5. 从零自学Hadoop(12):Hadoop命令中

    阅读目录 序 HDFS Commands User Commands Administration Commands Debug Commands 引用 系列索引 本文版权归mephisto和博客园共 ...

  6. 从零自学Hadoop(25):Impala相关操作下

    阅读目录 序 导入数据 查询 系列索引 本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作. 文章是哥(mephisto)写的,SourceLink 序 上一 ...

  7. 从零自学Hadoop系列索引

    本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作. 文章是哥(mephisto)写的,SourceLink 从零自学Hadoop(01):认识Hadoop ...

  8. 从零自学Hadoop(18):Hive的CLI和JDBC

    阅读目录 序 Hive CLI(old CLI) Beeline CLI(new CLI) JDBC Demo下载 系列索引 本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出 ...

  9. 从零自学Hadoop(03):Linux准备上

    阅读目录 序 检查列表 常用Linux命令 搭建环境 系列索引 本文版权归mephisto和博客园共有,欢迎转载,但须保留此段声明,并给出原文链接,谢谢合作. 文章是哥(mephisto)写的,Sou ...

随机推荐

  1. 1.Java基础之System对象

    毕向东老师Java基础学习笔记——System对象 今天学习Java中的System对象后,感觉这个对象对我们主要有以下几点用处. 1.获取当前操作系统版本和类型. 2.获取当前操作系统的path中的 ...

  2. 内存中OLTP与内存不足

    我已经写了好几次内存中OLTP的文章和”为什么我还不推荐内存中OLTP给用户”.今天我想进一步谈下内存中OLTP背后的内存需求,还有如果你内存不够的话会发生什么. 一切都与内存有关! 我们都知道很久之 ...

  3. asp.net WebService+Ajax调用

    default.aspx 代码如下: <%@ Page Language="C#" AutoEventWireup="true" CodeFile=&qu ...

  4. PHP5各个版本的新功能和新特性总结

    因为 PHP 那“集百家之长”的蛋疼语法,加上社区氛围不好,很多人对新版本,新特征并无兴趣.本文将会介绍自 PHP5.2 起,直至 PHP5.6 中增加的新特征 本文目录:PHP5.2 以前:auto ...

  5. C#中对象,字符串,dataTable、DataReader、DataSet,对象集合转换成Json字符串方法。

    C#中对象,字符串,dataTable.DataReader.DataSet,对象集合转换成Json字符串方法. public class ConvertJson { #region 私有方法 /// ...

  6. 背水一战 Windows 10 (33) - 控件(选择类): ListBox, RadioButton, CheckBox, ToggleSwitch

    [源码下载] 背水一战 Windows 10 (33) - 控件(选择类): ListBox, RadioButton, CheckBox, ToggleSwitch 作者:webabcd 介绍背水一 ...

  7. python 替换 文件夹下的 文件名称 及 文件内容

    示例效果: 1.替换某文件夹下的 文件夹及子文件夹 的名称 由OldStrDir 变为 NewStrDir: 2.替换某文件夹下的 文件夹及子文件夹 下 所有的文件的名称 由OldStrFile 变为 ...

  8. SpringMVC中servletFileUpload.parseRequest(request)解析为空获取不到数据问题

    原因分析 首先我们来看下Spring mvc 中文件上传的配置 <bean id="multipartResolver" class="org.springfram ...

  9. Visual Studio中UnitTesting单元测试模板代码生成

             在软件研发过程中,单元测试的重要性直接影响软件质量.经验表明一个尽责的单元测试方法将会在软件开发的某个阶段发现很多的Bug,并且修改它们的成本也很低.在软件开发的后期阶段,Bug的发 ...

  10. Lind.DDD.UoW~方法回调完成原子化操作

    回到目录 本文来自于实践中的不足 在最近开始过程中,遇到了一个问题,之前设计的工作单元UoW只支持Insert,Update,Delete三种操作,即开发人员可以将以上三种操作同时扔进工作单元,由工作 ...