fujing 2013-06-27
After a few hours tweaking and googling, I managed to install apache oozie 3.3.2 on Hadoop 1.1.1.
The document provided in apache oozie 3.3.2 is not very clear. After some googling, I found this blog is a great guide for you install oozie 3.3.1 on Hadoop 0.23.0.
http://srikanthayalasomayajulu.blogspot.sg/2013/02/apache-oozie-331-installation-on-apache.html
If you want to install oozie on MRv2/YARN, please follow the blog post.
Here we go, we're going to install oozie 3.3.2 on Hadoop 1.1.1, which is offically supported version.
Apache oozie 3.3.2 official quick start page: http://oozie.apache.org/docs/3.3.2/DG_QuickStart.html
My local environment:
Oozie server installation:
<!-- OOZIE -->
<property>
<name>hadoop.proxyuser.[OOZIE_SERVER_USER].hosts</name>
<value>[OOZIE_SERVER_HOSTNAME]</value>
</property>
<property>
<name>hadoop.proxyuser.[OOZIE_SERVER_USER].groups</name>
<value>[USER_GROUPS_THAT_ALLOW_IMPERSONATION]</value>
</property> Replaced [OOZIE_SERVER_USER] with gsun , [OOZIE_SERVER_HOSTNAME] with * and [OOZIE_GROUPS_THAT_ALLOW_IMPERSONATION] with * . TIP: in this blog post, the $OOZIE_HOME refers to ~/dev/oozie-3.3.2cd $OOZIE_HOME ./bin/mkdistro.sh -DskipTestsIt will take a while, go get a coffee, you'll be fine.
MacBookPro:oozie-3.3.2 gsun$ cd hadooplibs/
MacBookPro:hadooplibs gsun$ ls
hadoop-1/ hadoop-3/ hadoop-distcp-2/ hadoop-test-1/ hadoop-test-3/ target/
hadoop-2/ hadoop-distcp-1/ hadoop-distcp-3/ hadoop-test-2/ pom.xml
MacBookPro:hadooplibs gsun$ tree hadoop-1/
hadoop-1/
├── pom.xml
└── target
├── archive-tmp
├── hadooplibs
│ └── hadooplib-1.1.1.oozie-3.3.2
│ ├── commons-beanutils-1.7.0.jar
│ ├── commons-beanutils-core-1.8.0.jar
│ ├── commons-codec-1.4.jar
│ ├── commons-collections-3.2.1.jar
│ ├── commons-configuration-1.6.jar
│ ├── commons-digester-1.8.jar
│ ├── commons-el-1.0.jar
│ ├── commons-io-2.1.jar
│ ├── commons-lang-2.4.jar
│ ├── commons-logging-1.1.jar
│ ├── commons-math-2.1.jar
│ ├── commons-net-1.4.1.jar
│ ├── hadoop-client-1.1.1.jar
│ ├── hadoop-core-1.1.1.jar
│ ├── hsqldb-1.8.0.7.jar
│ ├── jackson-core-asl-1.8.8.jar
│ ├── jackson-mapper-asl-1.8.8.jar
│ ├── log4j-1.2.16.jar
│ ├── oro-2.0.8.jar
│ └── xmlenc-0.52.jar
├── maven-archiver
│ └── pom.properties
└── oozie-hadoop-1.1.1.oozie-3.3.2.jar
5 directories, 23 files
MacBookPro:hadooplibs gsun$ > cd $OOZIE_HOME > ./distro/target/oozie-3.3.2-distro/oozie-3.3.2/bin/oozie-setup.sh -extjs $OOZIE_HOME/webapp/src/main/webapp/ext-2.2.zipIf the build success, go to the next step, or refer to apache Oozie official docs for oozie-setup.sh usage.
> cd $OOZIE_HOME > vi ./distro/target/oozie-3.3.2-distro/oozie-3.3.2/conf/oozie-site.xmlChange the property below to true as shown.
<property>
<name>oozie.service.JPAService.create.db.schema</name>
<value>true</value>
<description>
Creates Oozie DB.
If set to true, it creates the DB schema if it does not exist. If the DB schema exists is a NOP.
If set to false, it does not create the DB schema. If the DB schema does not exist it fails start up.
</description>
</property> > cd $OOZIE_HOME > ./distro/target/oozie-3.3.2-distro/oozie-3.3.2/bin/ooziedb.sh create -sqlfile oozie.sql -runif the command is successfully run, the SQL has been created successfully.Start the oozie server.
> cd $OOZIE_HOME ./distro/target/oozie-3.3.2-distro/oozie-3.3.2/bin/oozied.sh run
java.lang.NoClassDefFoundError: org/apache/commons/configuration/Configuration java.lang.NoClassDefFoundError: org/apache/hadoop/util/ReflectionUtils