oozie作业失败

ha5z0ras  于 2021-06-02  发布在  Hadoop
关注(0)|答案(1)|浏览(305)

我正在尝试运行一个简单的oozie作业,使用sqoop从本地mysql数据库中提取数据。以下是my workflow.xml:

<workflow-app name="sqoopoozietest" xmlns="uri:oozie:workflow:0.1">
<start to="sqoopconnect"/>
<action name="sqoopconnect">
    <sqoop xmlns="uri:oozie:sqoop-action:0.2">
        <job-tracker>horton-n2.hdp.local:8050</job-tracker>
        <name-node>hdfs://horton-n1.hdp.local:8020</name-node>
        <prepare>
            <delete path="hdfs://horton-n1.hdp.local:8020/user/mannb/sqoopoozie/sqoopinput"/>
        </prepare>
        <configuration>
            <property>
                <name>mapred.compress.map.output</name>
                <value>true</value>
            </property>
        </configuration>
        <command>import  --connect jdbc:mysql://horton-n1.hdp.local/sqooptest --table sampledata --username sqoop --password sqoop123 --target-dir --driver com.mysql.jdbc.Driver hdfs://horton-n1.hdp.local:8020/user/mannb/sqoopoozie/sqoopinput -m 1</command>
    </sqoop>
    <ok to = "sqoopend"/>
    <error to = "kill"/>
</action>

   <kill name = "kill">
        <message>"Workflow failed."</message>
   </kill>

   <end name = "sqoopend" />
</workflow-app>

我从/var/log/oozie.log收到的主要错误是:
javax.servlet.jsp.el.elexception:函数“wf:errormessage”需要1个参数,但传递给0
我觉得这很奇怪,因为我正在向kill name消息传递一个参数:“workflow failed.”。
下面是我的job.properties文件:

nameNode=hdfs://horton-n1.hdp.local:8020
jobTracker=horton-n2.hdp.local:8050

queueName=default

# oozie.use.system.libpath=true

oozie.wf.application.path=${nameNode}/user/mannb/sqoopoozie/workflow.xml

非常感谢您的帮助。

nnvyjq4y

nnvyjq4y1#

更改代码如下。

<error to = "kill_job"/>

 <kill name = "kill_job">
        <message>Workflow failed</message>
 </kill>

相关问题