hadoop0.21.0中提供的测试工具

来源:互联网 发布:centos下mrtg安装配置 编辑:程序博客网 时间:2024/05/28 23:09

我们常常需要对HDFS或者mapreduce进行一些性能方面的测试,比如测试rpc的性能,测试DFS的IO读写性能,测试DFS的吞吐率性能,测试namenode的benchmark性能,mapreduce的sort性能等等。在hadoop的发行版中,其实已经提供了许多类似的工具,并已经打包成jar,供我们使用。以下是0.20.2中自带的一系列工具列表:

DFSCIOTest

Distributed i/o benchmark of libhdfs.

DistributedFSCheck

Distributed checkup of the file system consistency.

MRReliabilityTest

A program that tests the reliability of the MR framework by injecting faults/failures

TestDFSIO

Distributed i/o benchmark.

dfsthroughput

measure hdfs throughput

filebench:

Benchmark SequenceFile(Input|Output)Format (block,record compressed and uncompressed), Text(Input|Output)Format (compressed and uncompressed)

loadgen

Generic map/reduce load generator

mapredtest

A map/reduce test check.

minicluster

Single process HDFS and MR cluster.

nnbench

A benchmark that stresses the namenode.

testbigmapoutput

A map/reduce program that works on a very big non-splittable file and does identity map/reduce

testfilesystem

A test for FileSystem read/write.

testrpc

A test for rpc

testsequencefile

A test for flat files of binary key value pairs.

threadedmapbench:

A map/reduce benchmark that compares the performance of maps with multiple spills over maps with 1 spill

单独运行每个工具,都会有详细的帮助信息输出到命令行,根据命令行提示,就可以对很多想要进行性能测试的模块进行压力和性能测试。每个工具最终都会输出一个统计结果。若要定制自定义的压力测试工具,可以自己动手编写相应的压力测试程序,然后注册到org.apache.hadoop.test.AllTestDriver中。如想要了解每个benchmark工具的细节,可以从AllTestDriver中找到相应的测试工具的代码。

DFSCIOTest: 测试libhdfs中的分布式I/O的基准。Libhdfs是一个为C/C++应用程序提供HDFS文件服务的共享库。

DistributedFSCheck: 文件系统一致性的分布式检查。

JHLogAnalyzer: Job History Log analyzer.

MRReliabilityTest: MR的可靠性测试,通过注入failed task实现

TestDFSIO: 测试分布式I/O基准

fail: 对一个经常失败的job进行测试

filebench: SequenceFileInputFormat和SequenceFileOutputFormat的基准,这包含BLOCK压缩,RECORD压缩和非压缩的情况。TextInputFormat和TextOutputFormat的基准,包括压缩和非压缩的情况。

loadgen: 通用的MapReduce加载产生器。

mapredtest: MapReduce作业的测试和检测。

mrbench: A map/reduce benchmark that can create many small jobs

nnbench: NameNode在压力下的性能基准。

sleep: A job that sleeps at each map and reduce task.

testbigmapoutput:对未分割的大文件的mapreduce任务测试

testfilesystem: 文件系统的读写测试

testmapredsort: 对map/reduce中的排序框架的性能测试

testsequencefile:对只含有二进制的key/value对的文件测试

testsequencefileinputformat: 对sequence file的inputformat测试

testtextinputformat: 对text 的inputformat测试

threadedmapbench: 对比输出一个排序块的Map作业和输出多个排序块的Map作业的性能。

原创粉丝点击