Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

CDH 5.1.2. Oozie cannot initialize cluster error JA009

Solved Go to solution

CDH 5.1.2. Oozie cannot initialize cluster error JA009

New Contributor

I have installed CDH 5.1.2 using cloudera manager. Have configured for YARN. When I submit an oozie job I am getting the below error

 

JA009: Cannot initialize Cluster. Please check your configuration for mapreduce.frameworl k.name and the correspond server addresses.

 

I have checked the configuration files.. oozie-default.xml,oozie-site.xml,core-site.xml and everywhere the mapreduce.framework.name property is set to 'yarn'. Also set HADOOP_MAPRED_HOME=/opt/cloudera/parcels/CDH-5.2.0-1.cdh5.2.0.p0.36/lib/hadoop-mapreduce

 

Nothing has helped so far. 

 

I am able to submit YARN jobs from other clients such as hive,sqoop,pig etc.

 

Kindly help. Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: CDH 5.1.2. Oozie cannot initialize cluster error JA009

Explorer

Never mind. Issue got resolved. I thought I would post the job.properties and workflow.xml so that anyone else having this issue can refer here:

 

workflow.xml:

 

<workflow-app xmlns="uri:oozie:workflow:0.4" name="oozie-wf">
<start to="sqoop-wf1"/>
<action name="sqoop-wf1">
<sqoop xmlns="uri:oozie:sqoop-action:0.2">
<job-tracker>${jobTracker}</job-tracker>
<name-node>${nameNode}</name-node>
<command>import --connect jdbc:mysql://localhost/nosql --table forHive --username root --password test123 --m 1 --target-dir /user/kabeer/001</command>
<archive>/tmp/mysql-connector-java-5.1.33-bin.jar#mysql-connector-java-5.1.33-bin.jar</archive>
</sqoop>
<ok to="end"/>
<error to="fail"/>
</action>
<kill name="fail">
<message>Failed, Error Message[${wf:errorMessage(wf:lastErrorNode())}]</message>
</kill>
<end name="end"/>
</workflow-app>

 

 

Job.properties:

 

nameNode=hdfs://localhost:8020
job-tracker=localhost:8032
jobTracker=localhost:8032
queueName=default
weatherRoot=oozie
#mapreduce.jobtracker.kerberos.principal=foo
#dfs.namenode.kerberos.principal=foo
oozie.libpath=${nameNode}/user/oozie/share/lib/lib_20150226170905
# oozie.wf.application.path=${nameNode}/user/${user.name}/${weatherRoot}
oozie.wf.application.path=${nameNode}/user/kabeer/${weatherRoot}
outputDir=sqoop-output
oozie.use.system.libpath=true

4 REPLIES 4

Re: CDH 5.1.2. Oozie cannot initialize cluster error JA009

Master Guru
Its more than likely that Oozie is still running with MR1 config-set even though it has YARN libraries in it properly.

What MapReduce Service is associated as a dependency under CM -> Oozie -> Configuration? Make sure it is set to YARN, and restart your Oozie service. Does that help?

Re: CDH 5.1.2. Oozie cannot initialize cluster error JA009

Explorer

Hi Harsh

 

I am facing similar issue with cdh 5.2.0. I have ensured that everything points to YARN in mapred-site.xml and that oozie-site.xml is pointing to the right configuration files of hadoop.conf.

 

Please let me know of any solution that you would have come across for this issue. Below are the configuration files that I have been using.

 

Thanks,

Kabeer.

 

job.properties:

 

nameNode=hdfs://localhost:8020
job-tracker=localhost:8032
jobTracker=localhost:8032
queueName=default
weatherRoot=oozie
#mapreduce.jobtracker.kerberos.principal=foo
#dfs.namenode.kerberos.principal=foo
oozie.libpath=${nameNode}/user/oozie/share/lib
oozie.wf.application.path=${nameNode}/user/${user.name}/${weatherRoot}
outputDir=weather-ooze

 

workflow.xml

 

<workflow-app xmlns="uri:oozie:workflow:0.4" name="oozie-wf">
<start to="sqoop-wf1"/>
<action name="sqoop-wf1">
<sqoop xmlns="uri:oozie:sqoop-action:0.2">
<job-tracker>localhost:8032</job-tracker>
<name-node>localhost:8020</name-node>
<command>import --connect jdbc:mysql://localhost/employees --table forHive --username root --password test123 --m 1 </command>
</sqoop>
<ok to="end"/>
<error to="fail"/>
</action>
<kill name="fail">
<message>Failed, Error Message[${wf:errorMessage(wf:lastErrorNode())}]</message>
</kill>
<end name="end"/>
</workflow-app>

Highlighted

Re: CDH 5.1.2. Oozie cannot initialize cluster error JA009

Explorer

Never mind. Issue got resolved. I thought I would post the job.properties and workflow.xml so that anyone else having this issue can refer here:

 

workflow.xml:

 

<workflow-app xmlns="uri:oozie:workflow:0.4" name="oozie-wf">
<start to="sqoop-wf1"/>
<action name="sqoop-wf1">
<sqoop xmlns="uri:oozie:sqoop-action:0.2">
<job-tracker>${jobTracker}</job-tracker>
<name-node>${nameNode}</name-node>
<command>import --connect jdbc:mysql://localhost/nosql --table forHive --username root --password test123 --m 1 --target-dir /user/kabeer/001</command>
<archive>/tmp/mysql-connector-java-5.1.33-bin.jar#mysql-connector-java-5.1.33-bin.jar</archive>
</sqoop>
<ok to="end"/>
<error to="fail"/>
</action>
<kill name="fail">
<message>Failed, Error Message[${wf:errorMessage(wf:lastErrorNode())}]</message>
</kill>
<end name="end"/>
</workflow-app>

 

 

Job.properties:

 

nameNode=hdfs://localhost:8020
job-tracker=localhost:8032
jobTracker=localhost:8032
queueName=default
weatherRoot=oozie
#mapreduce.jobtracker.kerberos.principal=foo
#dfs.namenode.kerberos.principal=foo
oozie.libpath=${nameNode}/user/oozie/share/lib/lib_20150226170905
# oozie.wf.application.path=${nameNode}/user/${user.name}/${weatherRoot}
oozie.wf.application.path=${nameNode}/user/kabeer/${weatherRoot}
outputDir=sqoop-output
oozie.use.system.libpath=true

Re: CDH 5.1.2. Oozie cannot initialize cluster error JA009

Explorer
Had similar issue got resolved
Error
------
I had like this in workflow.xml
<job-tracker>localhost:8032</job-tracker>
<name-node>localhost:8020</name-node>

Changed it to the following
<job-tracker>${jobTracker}</job-tracker>
<name-node>${nameNode}</name-node>