hadoop编译报错
来源:互联网 发布:mysql 架构 编辑:程序博客网 时间:2024/06/05 00:34
错误1:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.5.1:testCompile (default-testCompile) on project hadoop-auth: Compilation failure: Compilation failure:
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[88,11] error: cannot access AbstractLifeCycle
[ERROR] class file for org.mortbay.component.AbstractLifeCycle not found
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[96,29] error: cannot access LifeCycle
[ERROR] class file for org.mortbay.component.LifeCycle not found
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[98,10] error: cannot find symbol
[ERROR] symbol: method start()
[ERROR] location: variable server of type Server
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[104,12] error: cannot find symbol
[ERROR] -> [Help 1]
需要修改源码下边的hadoop-common-project/hadoop-auth/pom.xml
Index: hadoop-common-project/hadoop-auth/pom.xml ===================================================================
--- hadoop-common-project/hadoop-auth/pom.xml (revision 1543124)
+++ hadoop-common-project/hadoop-auth/pom.xml (working copy)
@@ -54,6 +54,11 @@
</dependency>
<dependency>
<groupId>org.mortbay.jetty</groupId>
+<artifactId>jetty-util</artifactId>
+<scope>test</scope>
+</dependency>
+<dependency>
+<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty</artifactId>
<scope>test</scope>
</dependency>
添加加号部分代码。
错误2:
[ERROR] Failed to execute goal org.apache.hadoop:hadoop-maven-plugins:2.2.0:protoc (compile-protoc) on project hadoop-common: org.apache.maven.plugin.MojoExecutionException: 'protoc --version' did not return a version -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1]
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :hadoop-common
hadoop2.2.0编译需要protoc2.5.0的支持,所以还要下载protoc,下载地址:https://code.google.com/p/protobuf/downloads/list
protoc依赖包:gcc,gcc-c++,make
tar -xvf protobuf-2.5.0.tar.bz2
cd protobuf-2.5.0
./configure --prefix=/usr/local/protoc
make && make install
然后配置环境变量:
export PATH=/usr/local/protoc/bin:$PATH
立即生效:
source /etc/profile
清除安装:
mvn clean install –DskipTests
重新编译:
mvn package -Pdist,native -DskipTests -Dtar
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.5.1:testCompile (default-testCompile) on project hadoop-auth: Compilation failure: Compilation failure:
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[88,11] error: cannot access AbstractLifeCycle
[ERROR] class file for org.mortbay.component.AbstractLifeCycle not found
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[96,29] error: cannot access LifeCycle
[ERROR] class file for org.mortbay.component.LifeCycle not found
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[98,10] error: cannot find symbol
[ERROR] symbol: method start()
[ERROR] location: variable server of type Server
[ERROR] /home/hduser/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[104,12] error: cannot find symbol
[ERROR] -> [Help 1]
需要修改源码下边的hadoop-common-project/hadoop-auth/pom.xml
Index: hadoop-common-project/hadoop-auth/pom.xml ===================================================================
--- hadoop-common-project/hadoop-auth/pom.xml (revision 1543124)
+++ hadoop-common-project/hadoop-auth/pom.xml (working copy)
@@ -54,6 +54,11 @@
</dependency>
<dependency>
<groupId>org.mortbay.jetty</groupId>
+<artifactId>jetty-util</artifactId>
+<scope>test</scope>
+</dependency>
+<dependency>
+<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty</artifactId>
<scope>test</scope>
</dependency>
添加加号部分代码。
错误2:
[ERROR] Failed to execute goal org.apache.hadoop:hadoop-maven-plugins:2.2.0:protoc (compile-protoc) on project hadoop-common: org.apache.maven.plugin.MojoExecutionException: 'protoc --version' did not return a version -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1]
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :hadoop-common
hadoop2.2.0编译需要protoc2.5.0的支持,所以还要下载protoc,下载地址:https://code.google.com/p/protobuf/downloads/list
protoc依赖包:gcc,gcc-c++,make
tar -xvf protobuf-2.5.0.tar.bz2
cd protobuf-2.5.0
./configure --prefix=/usr/local/protoc
make && make install
然后配置环境变量:
export PATH=/usr/local/protoc/bin:$PATH
立即生效:
source /etc/profile
清除安装:
mvn clean install –DskipTests
重新编译:
mvn package -Pdist,native -DskipTests -Dtar
0 0
- hadoop编译报错
- HADOOP编译WordCount.java文件报错
- hadoop-2.2.0采用源码编译安装启动报错
- Hadoop重新编译WordCount程序报错:cannot access Options
- 用命令行运行hadoop程序WordCount,编译hadoop程序报错
- hadoop报错日志
- Hadoop 之报错
- 运行hadoop报错
- hadoop安装报错
- Hadoop报错
- hadoop报错ConnectionRefused
- hadoop启动报错
- Hadoop报错
- hadoop报错10020
- hadoop编译源代码报错:package-info.java: 未结束的字符串字面值
- Maven编译HADOOP的common项目报错 。。。exec (compile-proto)。。。
- hadoop2.2.0遇到64位操作系统平台报错,重新编译hadoop
- 【甘道夫】win7环境下eclipse连接hadoop报错简单解决:重编译FileUtil.java
- 转载自百度百科——java记——关于java中decimalformat类
- pc与Android进行USB通信
- Java反射之java.beans包
- Light Bulb(三分)
- atoi-字符串转Int的实现
- hadoop编译报错
- iOS中地图功能的实现
- Ubuntu下设置自定义桌面分辨率
- 判断搜索引擎来路进行跳转的代码(PHP+JS)
- CMake 总结与备忘
- cropper
- css类的两种使用方法
- 图形图像处理-之-高质量的快速的图像缩放 中篇 二次线性插值和三次卷积插值
- 解密ThreadLocal