(转)maven3.3.9编译oozie4.3.0
1.Java版本1.8
[root@sht-sgmhadoopdn-04 app]# java -version
java version "1.8.0_66"
Java(TM) SE Runtime Environment (build 1.8.0_66-b17)
Java HotSpot(TM) 64-Bit Server VM (build 25.66-b17, mixed mode)
[root@sht-sgmhadoopdn-04 app]#
2.maven-3.3.9安装
[root@sht-sgmhadoopdn-04 app]# wget http://mirrors.hust.edu.cn/apache/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.tar.gz
[root@sht-sgmhadoopdn-04 app]# tar -xzvf apache-maven-3.3.9-bin.tar.gz
[root@sht-sgmhadoopdn-04 app]# ln -s apache-maven-3.3.9 maven
[root@sht-sgmhadoopdn-04 app]# vi /etc/profile
M2_HOME=/root/learnproject/app/maven
PATH=$M2_HOME/bin:$PATH
[root@sht-sgmhadoopdn-04 app]# source /etc/profile
[root@sht-sgmhadoopdn-04 app]# mvn -version
Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-11T00:41:47+08:00)
Maven home: /root/learnproject/app/maven
Java version: 1.7.0_67, vendor: Oracle Corporation
Java home: /usr/java/jdk1.7.0_67-cloudera/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "2.6.32-431.el6.x86_64", arch: "amd64", family: "unix"
[root@sht-sgmhadoopdn-04 app]#
3.修改maven的仓库设置
#这里我们需要编译oozie,所以不用阿里云仓库(很多依赖不全),改成使用maven的中央仓库。
[root@sht-sgmhadoopdn-04 app]# cd /root/learnproject/app/maven/conf
[root@sht-sgmhadoopdn-04 conf]# vi settings.xml
<mirror>
<id>Central</id>
<mirrorOf>*</mirrorOf>
<name>Central</name>
<url>http://central.maven.org/maven2/</url>
</mirror>
<!-- 阿里云镜像 -->
<mirror>
<id>nexus-aliyun</id>
<mirrorOf>*</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>
4.oozie-4.3.0源代码文件下载解压
[root@sht-sgmhadoopdn-04 app]# mkdir oozie_source
[root@sht-sgmhadoopdn-04 app]# cd oozie_source
[root@sht-sgmhadoopdn-04 oozie_source]# wget http://apache.fayea.com/oozie/4.3.0/oozie-4.3.0.tar.gz
[root@sht-sgmhadoopdn-04 oozie_source]# tar -xzvf oozie-4.3.0.tar.gz
5.修改pom.xml,改为1.8
[root@sht-sgmhadoopdn-04 oozie_source]# cd oozie-4.3.0
[root@sht-sgmhadoopdn-04 oozie_source]# vi pom.xml
点击(此处)折叠或打开
- <targetJavaVersion>1.8</targetJavaVersion>
- <sourceJavaVersion>1.8</sourceJavaVersion>
- <minJavaVersion>1.7</minJavaVersion>
6.第一次编译
[root@sht-sgmhadoopdn-04 oozie_source]# bin/mkdistro.sh -DskipTests -Puber -Phadoop-2 \
-Dhadoop.version=2.7.2 \
-Dhadoop.auth.version=2.7.2 \
-Ddistcp.version=2.7.2 \
-Dsqoop.version=1.4.3 \
-Dhive.version=1.2.0 \
-Dhbase.version=0.94.27
.........
.........
[INFO] Final Memory: 112M/606M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project oozie-core: Could not resolve dependencies for project org.apache.oozie:oozie-core:jar:4.3.0:
Could not find artifact org.pentaho:pentaho-aggdesigner-algorithm:jar:5.1.5-jhyde in Central (http://central.maven.org/maven2/) -> [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] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn -rf :oozie-core
7.Could not find artifact org.pentaho:pentaho-aggdesigner-algorithm:jar:5.1.5-jhyde in Central
7.1下载不了该jar包 我就手工下载,先找到下载地址,就会发现该jar包来源根本不是maven的central仓库,而是spring
http://repo.spring.io/plugins-release/org/pentaho/pentaho-aggdesigner-algorithm/5.1.5-jhyde/pentaho-aggdesigner-algorithm-5.1.5-jhyde.jar
7.2 进机器的~/.m2/repository/org/pentaho/pentaho-aggdesigner-algorithm/5.1.5-jhyde/,清除,手工上传win7下载好的jar包
[root@sht-sgmhadoopdn-04 5.1.5-jhyde]# rm -rf *
[root@sht-sgmhadoopdn-04 5.1.5-jhyde]# wget http://repo.spring.io/plugins-release/org/pentaho/pentaho-aggdesigner-algorithm/5.1.5-jhyde/pentaho-aggdesigner-algorithm-5.1.5-jhyde.jar
[root@sht-sgmhadoopdn-04 5.1.5-jhyde]# ll
total 48
-rw-r--r-- 1 root root 48557 Apr 25 16:44 pentaho-aggdesigner-algorithm-5.1.5-jhyde.jar
[root@sht-sgmhadoopdn-04 5.1.5-jhyde]#
8.第二次编译
[root@sht-sgmhadoopdn-04 oozie_source]# bin/mkdistro.sh -DskipTests -Puber -Phadoop-2 \
-Dhadoop.version=2.7.2 \
-Dhadoop.auth.version=2.7.2 \
-Ddistcp.version=2.7.2 \
-Dsqoop.version=1.4.3 \
-Dhive.version=1.2.0 \
-Dhbase.version=0.94.27
.........
.........
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-site-plugin:2.0-beta-6:site (default) on project oozie-docs:
Execution default of goal org.apache.maven.plugins:maven-site-plugin:2.0-beta-6:site failed: Plugin org.apache.maven.plugins:maven-site-plugin:2.0-beta-6 or one of its dependencies
could not be resolved: The following artifacts could not be resolved: org.apache.maven.doxia:doxia-module-twiki:jar:1.0-alpha-9.2y,
org.apache.maven.doxia:doxia-core:jar:1.0-alpha-9.2y: Could not find artifact org.apache.maven.doxia:doxia-module-twiki:jar:1.0-alpha-9.2y
in Central (http://central.maven.org/maven2/) -> [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] http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn -rf :oozie-docs
9. could not be resolved: org.apache.maven.doxia:doxia-module-twiki:jar:1.0-alpha-9.2y, org.apache.maven.doxia:doxia-core:jar:1.0-alpha-9.2y
9.1下载不了该jar包 我就手工下载,先找到下载地址,就会发现该jar包来源根本不是maven的central仓库,而是cloudera
doxia-module-twiki-1.0-alpha-9.2y.jar:
https://repository.cloudera.com/content/repositories/releases/org/apache/maven/doxia/doxia-module-twiki/1.0-alpha-9.2y/doxia-module-twiki-1.0-alpha-9.2y.jar
doxia-core-1.0-alpha-9.2y.jar:
https://repository.cloudera.com/content/repositories/releases/org/apache/maven/doxia/doxia-core/1.0-alpha-9.2y/doxia-core-1.0-alpha-9.2y.jar
9.2进~/.m2/repository/org/apache/maven/doxia/doxia-module-twiki/1.0-alpha-9.2y,下载 doxia-module-twiki-1.0-alpha-9.2y.jar
[root@sht-sgmhadoopdn-04 1.0-alpha-9.2y]# pwd
/root/.m2/repository/org/apache/maven/doxia/doxia-module-twiki/1.0-alpha-9.2y
[root@sht-sgmhadoopdn-04 1.0-alpha-9.2y]# rm -rf *
[root@sht-sgmhadoopdn-04 1.0-alpha-9.2y]# wget https://repository.cloudera.com/content/repositories/releases/org/apache/maven/doxia/doxia-module-twiki/1.0-alpha-9.2y/doxia-module-twiki-1.0-alpha-9.2y.jar --no-check-certificate
9.3进~/.m2/repository/org/apache/maven/doxia/doxia-core/1.0-alpha-9.2y,下载 doxia-core-1.0-alpha-9.2y.jar:
[root@sht-sgmhadoopdn-04 1.0-alpha-9.2y]# pwd
/root/.m2/repository/org/apache/maven/doxia/doxia-module-twiki
[root@sht-sgmhadoopdn-04 1.0-alpha-9.2y]# rm -rf *
[root@sht-sgmhadoopdn-04 1.0-alpha-9.2y]# wget https://repository.cloudera.com/content/repositories/releases/org/apache/maven/doxia/doxia-core/1.0-alpha-9.2y/doxia-core-1.0-alpha-9.2y.jar --no-check-certificate
9.第三次编译
[root@sht-sgmhadoopdn-04 oozie_source]# bin/mkdistro.sh -DskipTests -Puber -Phadoop-2 \
-Dhadoop.version=2.7.2 \
-Dhadoop.auth.version=2.7.2 \
-Ddistcp.version=2.7.2 \
-Dsqoop.version=1.4.3 \
-Dhive.version=1.2.0 \
-Dhbase.version=0.94.27
........
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Apache Oozie Main .................................. SUCCESS [ 2.121 s]
[INFO] Apache Oozie Hadoop Utils hadoop-2-4.3.0 ........... SUCCESS [ 3.706 s]
[INFO] Apache Oozie Hadoop Distcp hadoop-2-4.3.0 .......... SUCCESS [ 0.178 s]
[INFO] Apache Oozie Hadoop Auth hadoop-2-4.3.0 Test ....... SUCCESS [ 0.781 s]
[INFO] Apache Oozie Hadoop Libs ........................... SUCCESS [ 0.043 s]
[INFO] Apache Oozie Client ................................ SUCCESS [ 24.672 s]
[INFO] Apache Oozie Share Lib Oozie ....................... SUCCESS [ 3.791 s]
[INFO] Apache Oozie Share Lib HCatalog .................... SUCCESS [ 5.554 s]
[INFO] Apache Oozie Share Lib Distcp ...................... SUCCESS [ 1.478 s]
[INFO] Apache Oozie Core .................................. SUCCESS [01:24 min]
[INFO] Apache Oozie Share Lib Streaming ................... SUCCESS [ 6.369 s]
[INFO] Apache Oozie Share Lib Pig ......................... SUCCESS [ 7.963 s]
[INFO] Apache Oozie Share Lib Hive ........................ SUCCESS [ 9.024 s]
[INFO] Apache Oozie Share Lib Hive 2 ...................... SUCCESS [ 7.739 s]
[INFO] Apache Oozie Share Lib Sqoop ....................... SUCCESS [ 3.303 s]
[INFO] Apache Oozie Examples .............................. SUCCESS [ 7.334 s]
[INFO] Apache Oozie Share Lib Spark ....................... SUCCESS [ 11.843 s]
[INFO] Apache Oozie Share Lib ............................. SUCCESS [ 29.395 s]
[INFO] Apache Oozie Docs .................................. SUCCESS [ 16.603 s]
[INFO] Apache Oozie WebApp ................................ SUCCESS [01:23 min]
[INFO] Apache Oozie Tools ................................. SUCCESS [ 5.716 s]
[INFO] Apache Oozie MiniOozie ............................. SUCCESS [ 3.058 s]
[INFO] Apache Oozie Distro ................................ SUCCESS [01:05 min]
[INFO] Apache Oozie ZooKeeper Security Tests .............. SUCCESS [ 20.784 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 06:47 min
[INFO] Finished at: 2017-04-25T17:32:58+08:00
[INFO] Final Memory: 581M/1067M
[INFO] ------------------------------------------------------------------------
Oozie distro created, DATE[2017.04.25-09:26:09GMT] VC-REV[unavailable], available at [/root/learnproject/app/oozie-source/oozie-4.3.0/distro/target]
10.生成的文件oozie-4.3.0-distro.tar.gz
[root@sht-sgmhadoopdn-04 oozie-4.3.0]# cd /root/learnproject/app/oozie-source/oozie-4.3.0/distro/target
[root@sht-sgmhadoopdn-04 target]# ll
total 440024
drwxr-xr-x 2 root root 4096 Apr 25 17:31 antrun
drwxr-xr-x 2 root root 4096 Apr 25 17:31 archive-tmp
drwxr-xr-x 3 root root 4096 Apr 25 17:31 classes
drwxr-xr-x 2 root root 4096 Apr 25 17:31 maven-archiver
drwxr-xr-x 3 root root 4096 Apr 25 17:31 maven-shared-archive-resources
drwxr-xr-x 3 root root 4096 Apr 25 17:32 oozie-4.3.0-distro
-rw-r--r-- 1 root root 450528886 Apr 25 17:32 oozie-4.3.0-distro.tar.gz
-rw-r--r-- 1 root root 14458 Apr 25 17:31 oozie-distro-4.3.0.jar
drwxr-xr-x 3 root root 4096 Apr 25 17:31 test-classes
drwxr-xr-x 3 root root 4096 Apr 25 17:31 tomcat
[root@sht-sgmhadoopdn-04 target]# ll oozie-4.3.0-distro.tar.gz
-rw-r--r-- 1 root root 450528886 Apr 25 17:32 oozie-4.3.0-distro.tar.gz
以上内容转自 http://m.blog.itpub.net/30089851/viewspace-2137979/
(转)maven3.3.9编译oozie4.3.0的更多相关文章
- Oozie4.2.0配置安装实战
软件版本号: Oozie4.2.0.Hadoop2.6.0,Spark1.4.1.Hive0.14.Pig0.15.0.Maven3.2.JDK1.7,zookeeper3.4.6.HBase1.1. ...
- Ubuntu12.04-x64编译Hadoop2.2.0和安装Hadoop2.2.0集群
本文Blog地址:http://www.cnblogs.com/fesh/p/3766656.html 本文对Hadoop-2.2.0源码进行重新编译(64位操作系统下不重新编译会有版本问题) ...
- oozie4.3.0的安装与配置 + hadoop2.7.3
安装步骤 mysql的配置 oozie的安装 oozie的配置 oozie的启动与登录 常用oozie的命令 1. mysql的配置 mysql的安装自行解决,然后在mysql上 创建oozie数据库 ...
- CentOS 64位上编译 Hadoop2.6.0
由于hadoop-2.6.0.tar.gz安装包是在32位机器上编译的,64位的机器加载本地库.so文件时会出错,比如: java.lang.UnsatisfiedLinkError: org.apa ...
- linux下编译gcc6.2.0
linux下编译gcc6.2.0 在archlinx的下gcc已经更新到6.2.1了,win10的WSL下还是gcc4.8.官方源没有比较新的版本,于是自己编译使用. GCC6的几个新特性 GCC 6 ...
- vs2016x64&&qt5.7.1编译osg3.4.0&&osgEarth2.7
此文仅备忘: 1.安装VS2013_Cn_Ult 2.安装qt-opensource-windows-x86-msvc2013_64-5.7.1 设置环境变量QTDIR,并将其bin加入到path中. ...
- VS2015编译Qt5.7.0生成支持XP的静态库(很不错)
一.编译工具 1.VS2015 编译Qt5.7.0的所需VS版本:Visual Studio 2013 (Update1)或Visual Studio 2015 (Update2).因为Update补 ...
- vs2013编译boost1.55.0 32/64位
在使用vs2013编译boost-1.55.0之前,先要给boost做下修改: boost_1_55_0\boost\intrusive\detail\has_member_function_call ...
- 编译hadoop2.6.0
具体情况比较曲折:hadoop2.6.0编译不过 错误如下: 这个kms模块始终编译不过,最后得出结论国内的aliyun maven仓库有问题, 在编译hadoop2.2.0 可以通过,因为这个版本的 ...
随机推荐
- 转:mac下安装homebrew
见: http://brew.sh 在命令行打开:
- (剑指Offer)面试题57:删除链表中的重复结点
题目: 在一个排序的链表中,存在重复的结点,请删除该链表中重复的结点,重复的结点不保留,返回链表头指针. 例如,链表1->2->3->3->4->4->5 处理后为 ...
- 解决ARC下performselector-may-cause-a-leak-because-its-selector-is-unknown 警告
在ARC下使用 [theTarget performSelector:theTarget withObject:Nil]; 会出现警告:performselector-may-cause-a-leak ...
- OpenJudge百炼习题解答(C++)--题4010:2011
题: 总时间限制: 1000ms 内存限制: 65536kB 描写叙述 已知长度最大为200位的正整数n.请求出2011^n的后四位. 输入 第一行为一个正整数k,代表有k组数据,k<=2 ...
- ionic 滚动条问题
方案一: 设置 ion-content ---> overflow-scroll="false"
- SqlServer字段说明查询及快速查看表结构
SqlServer字段说明查询 SELECT t.[name] AS 表名,c.[name] AS 字段名,cast(ep.[value] )) AS [字段说明] FROM sys.tables A ...
- 查看正在执行的sql语句
;WITH t AS( SELECT [Spid] = session_Id, ecid, [Database] = DB_NAME(sp.dbid), [User] = nt_username, [ ...
- HBase源代码分析之HRegionServer上MemStore的flush处理流程(一)
在<HBase源代码分析之HRegion上MemStore的flsuh流程(一)>.<HBase源代码分析之HRegion上MemStore的flsuh流程(二)>等文中.我们 ...
- C/S和B/S 赞美创新,好酸啊。
似乎是一个很古老的话题啊...翻出来炒冷饭也是很有趣的. 昨天聊iDempiere时说到了Client这个词,我和人家说我依然会条件反射般想到了C/S,从而又SB般感慨了一番世风日下,人心不古.... ...
- 从程序员到CTO的Java技术路线图 JAVA职业规划 JAVA职业发展路线图 系统后台框架图、前端工程师技能图 B2C电子商务基础系统架构解析
http://zz563143188.iteye.com/blog/1877266在技术方面无论我们怎么学习,总感觉需要提升自已不知道自己处于什么水平了.但如果有清晰的指示图供参考还是非常不错的,这样 ...