[英]Oozie shell action failed to exec java in Linux
我们已经提交了以下Oozie工作流程工作。 它在Windows群集中执行,但在Linux中失败。
<workflow-app xmlns='uri:oozie:workflow:0.3' name='shell-wf'>
<start to='shell1' />
<action name='shell1'>
<shell xmlns="uri:oozie:shell-action:0.1">
<job-tracker>${jobTracker}</job-tracker>
<name-node>${nameNode}</name-node>
<configuration>
<property>
<name>mapred.job.queue.name</name>
<value>${queueName}</value>
</property>
</configuration>
<exec>Java</exec>
<argument>A</argument>
<argument>B</argument>
<file>${EXEC}#${EXEC}</file> <!--Copy the executable to compute node's current working directory -->
</shell>
<ok to="end" />
<error to="fail" />
</action>
<kill name="fail">
<message>Script failed, error message[${wf:errorMessage(wf:lastErrorNode())}]</message>
</kill>
<end name='end' />
</workflow-app>
但是当我执行上述工作流文件时,抛出的异常无法运行Java程序。 没有这样的文件或目录 。
如果外壳程序脚本有一个外壳程序操作,并且该外壳程序脚本中的任何命令均失败,则必须在外壳程序脚本中添加#!/bin/bash -e
以捕获转换的失败代码。 然后它将被捕获到输出中,并且只会杀死您的工作流程。 否则,即使shell操作可能已失败,它也将成功退出。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.