编译hadoop2.2.0源码时,
mvn install -DskipTests
[ERROR] COMPILATION ERROR : [INFO] ------------------------------------------------------------- [ERROR] /home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[86,13] 无法訪问 org.mortbay.component.AbstractLifeCycle 未找到 org.mortbay.component.AbstractLifeCycle 的类文件 server = new Server(0); [ERROR] /home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[96,29] 无法訪问 org.mortbay.component.LifeCycle 未找到 org.mortbay.component.LifeCycle 的类文件 server.getConnectors()[0].setHost(host); [ERROR] /home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[98,10] 找不到符号 符号: 方法 start() 位置: 类 org.mortbay.jetty.Server [ERROR] /home/test/work/env/hadoop/hadoop-2.2.0-src/hadoop-common-project/hadoop-auth/src/test/java/org/apache/hadoop/security/authentication/client/AuthenticatorTestCase.java:[104,12] 找不到符号 符号: 方法 stop() 位置: 类 org.mortbay.jetty.Server [INFO] 4 errors [INFO] ------------------------------------------------------------- [INFO] ------------------------------------------------------------------------
不想看英文的,就直接改动hadoop-common-project/hadoop-auth/pom.xml,加入一个dependency:
<dependency> <groupId>org.mortbay.jetty</groupId> <artifactId>jetty-util</artifactId> <scope>test</scope> </dependency>
编译hadoop2.2.0源码时报错,布布扣,bubuko.com
原文地址:http://www.cnblogs.com/mengfanrong/p/3825841.html