失败的oozie启动程序,无法运行程序

ebdffaop  于 2021-06-26  发布在  Hive
关注(0)|答案(1)|浏览(471)

我正在尝试用一个非常基本的脚本运行oozie工作流。脚本本身非常简单,它接受一个csv文件并将其加载到impala中的一个表中。我的工作流程是这样的。

<workflow-app xmlns='uri:oozie:workflow:0.5' name='TEST'>

<global>
    <job-tracker>${jobTracker}</job-tracker>
    <name-node>${nameNode}</name-node>
    <configuration>
        <property>
            <name>mapreduce.job.queuename</name>
            <value>${queueName}</value>
        </property>
    </configuration>
</global>

<start to='postLoad' />
<action name="postLoad">
    <shell xmlns="uri:oozie:shell-action:0.3">
        <exec>${nameNode}/${baseCodePath}/Util/Test.sh</exec>
        <env-var>impalaConn=${impalaConn}</env-var>
        <env-var>xferUser=${xferUser}</env-var>
        <env-var>ingUser=${ingUser}</env-var>
        <env-var>explTableName=${explTableName}</env-var>
        <env-var>stagingPath=${stagingPath}</env-var>
        <file>${nameNode}/${baseCodePath}/Util/Test.sh</file>
        <file>${nameNode}/${commonCodePath}/Util/loadUsrEnv.sh</file>
    </shell>
 ...

然而,当我运行它时,我似乎总是得到这个错误,我不知道为什么它不能运行程序。目录/文件都指向正确的位置。 Failing Oozie Launcher, Main class [org.apache.oozie.action.hadoop.ShellMain], main() threw exception, Cannot run program "Test.sh" (in directory "/data13/yarn/nm/usercache/user/appcache/application"): error=2, No such file or directory java.io.IOException: Cannot run program "Test.sh" (in directory "/data13/yarn/nm/usercache/user/appcache/application"): error=2, No such file or directory

qhhrdooz

qhhrdooz1#

使用

<exec>Test.sh</exec>

这个 <file> 标记告诉oozie将文件从hdfs位置下载到yarn容器目录

相关问题