Support Questions

Find answers, ask questions, and share your expertise

Oozie sqoop job failing

avatar
Explorer

Hi,

I am successfully able to do sqoop action from shell. But not able to do with oozie. I have read several question in hortonworks that states need to add mysql jar in oozie/lib. I have added that too.. but still no success.

Main class [org.apache.oozie.action.hadoop.SqoopMain], exit code [1]

My workflow.xml looks like

<action name="sqoop-action">
   <sqoop xmlns="uri:oozie:sqoop-action:0.2">
      <job-tracker>${jobTracker}</job-tracker>
      <name-node>${nameNode}</name-node>
      <prepare>
         <delete path="${deleteHdfsPath}"/>
      </prepare>
      <configuration>
         <property>
            <name>oozie.hive.defaults</name>
            <value>/usr/hdp/current/hive-client/conf/hive-site.xml</value>
         </property>
      </configuration>
      <command>${command}</command>
      <archive>mysql-connector-java.jar#mysql-connector-java.jar</archive>
   </sqoop>
   <ok to="hive-action" />
   <error to="kill" />
</action>oozielog.zip

I am attaching my log file as well Can anybody help me ?

1 ACCEPTED SOLUTION

avatar
Master Guru

Your sqoop command begins with "sqoop":

No such sqoop tool: sqoop. See 'sqoop help'.Intercepting System.exit(1)

Remove "sqoop" from the command, it should start with "import", and retry.

View solution in original post

3 REPLIES 3

avatar
Master Guru

Your sqoop command begins with "sqoop":

No such sqoop tool: sqoop. See 'sqoop help'.Intercepting System.exit(1)

Remove "sqoop" from the command, it should start with "import", and retry.

avatar
Explorer

Thanks, It was a silly mistake.

avatar
Master Guru

No problems, it can happen to the best of us. Also glad to hear that it worked for your, because many people have been having troubles with Oozie Sqoop actions recently. By the way, for me it worked without specifying "archive" in the workflow file, I just uploaded mysql-connector jar to Oozie Sqoop share lib. Happy sqooping!