Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I specify multiple libpath in oozie job?

My oozie job uses 2 jars x.jar and y.jar and following is my job.properties file.

oozie.libpath=/lib
oozie.use.system.libpath=true

This works perfectly when both the jars are present at same location on HDFS at /lib/x.jar and /lib/y.jar

Now I have 2 jars placed at different locations /lib/1/x.jar and /lib/2/y.jar.
How can I re-write my code such that both the jars are used while running the map reduce job?

Note: I have already refernced the answer How to specify multiple jar files in oozie but, this does not solve my problem

like image 494
nikoo28 Avatar asked Nov 15 '15 00:11

nikoo28


People also ask

How do I add a sharelib to an Oozie workflow?

(I see that in a lot of workflows.) Oozie knows where the ShareLib is and will include it automatically if you set oozie.use.system.libpath=true in job.properties. Create a directory named “lib” next to your workflow.xml in HDFS and put jars in there.

How do I check the workflow job status in Oozie?

To check the workflow job status via the Oozie web console, with a browser go to http://localhost:8080/oozie . To avoid having to provide the -oozie option with the Oozie URL with every oozie command, set OOZIE_URL env variable to the Oozie URL in the shell environment. For example:

Where can I find Oozie examples in HDFS?

Oozie examples are bundled within the Oozie distribution in the oozie-examples.tar.gz file. Expanding this file will create an examples/ directory in the local file system. The examples/ directory must be copied to the user HOME directory in HDFS: NOTE: If an examples directory already exists in HDFS, it must be deleted before copying it again.

What is Oozie localoozie?

Oozie provides a embedded Oozie implementation, LocalOozie , which is useful for development, debugging and testing of workflow applications within the convenience of an IDE. The code snipped below shows the usage of the LocalOozie class. All the interaction with Oozie is done using Oozie OozieClient Java API, as shown in the previous section.


1 Answers

Found the answer at
http://blog.cloudera.com/blog/2014/05/how-to-use-the-sharelib-in-apache-oozie-cdh-5/
Turns out that I can specify multiple paths separated by comma in the job.properties file:

oozie.libpath=/path/to/jars,another/path/to/jars
like image 89
nikoo28 Avatar answered Nov 15 '22 05:11

nikoo28