ssslinppp

  博客园 :: 首页 :: 博问 :: 闪存 :: 新随笔 :: 联系 :: 订阅 订阅 :: 管理 ::
JDK版本的要求
  • Hadoop 2.7 以及之后的版本,需要JDK 7;
  • Hadoop 2.6 以及之前的版本,支持JDK 6;

对于Hadoop1.x.x版本,只需要引入1个jar:
  1. hadoop-core
对于Hadoop2.x.x版本,需要引入4个jar:
  1. hadoop-common
  2. hadoop-hdfs
  3. hadoop-mapreduce-client-core
  4. hadoop-client
  5. jdk.tools(一般需要引入,否则报错)


需要的Jar包 (对应版本:2.x.x)


  1. <properties>
  2. <hadoopVersion>2.5.2</hadoopVersion>
  3. </properties>
  4. <!-- Hadoop start -->
  5. <dependency>
  6. <groupId>org.apache.hadoop</groupId>
  7. <artifactId>hadoop-common</artifactId>
  8. <version>${hadoopVersion}</version>
  9. </dependency>
  10. <dependency>
  11. <groupId>org.apache.hadoop</groupId>
  12. <artifactId>hadoop-hdfs</artifactId>
  13. <version>${hadoopVersion}</version>
  14. </dependency>

  15. <dependency>
  16. <groupId>org.apache.hadoop</groupId>
  17. <artifactId>hadoop-mapreduce-client-core</artifactId>
  18. <version>${hadoopVersion}</version>
  19. </dependency>
  20. <dependency>
  21. <groupId>org.apache.hadoop</groupId>
  22. <artifactId>hadoop-client</artifactId>
  23. <version>${hadoopVersion}</version>
  24. </dependency>
  25. <!-- Hadoop -->
  26. <dependency>
  27. <groupId>jdk.tools</groupId>
  28. <artifactId>jdk.tools</artifactId>
  29. <version>1.6</version>
  30. <scope>system</scope>
  31. <systemPath>${JAVA_HOME}/lib/tools.jar</systemPath>
  32. </dependency>

需要的Jar包 (对应版本:1.2.1)
  1. <properties>
  2. <hadoopVersion>1.2.1</hadoopVersion>
  3. </properties>
  4. <dependency>
  5. <groupId>org.apache.hadoop</groupId>
  6. <artifactId>hadoop-core</artifactId>
  7. <version>${hadoopVersion}</version>
  8. </dependency>














posted on 2016-10-11 10:57  ssslinppp  阅读(4863)  评论(0编辑  收藏  举报