Oozie运行Shell的一些问题
另一篇文章有说过,Oozie会随机选择一台机器运行shell脚本。 因此必须保证每台机器都有能正常运行该脚本,其中包括:必要的文件,环境变量,包等。 要查看shell运行的错误信息,可以到hadoop的jobtracker网页查看。 问题1:No such file or directory 如果是提示找不到shell脚本,那就说明脚本没有被复制到对应的电脑上。在workflow.xml里面,通过file属性可以自动部署该文件。
<shell xmlns="uri:oozie:shell-action:0.1"> <job-tracker>${jobTracker}</job-tracker> <name-node>${nameNode}</name-node> <exec>for_fun.sh</exec> <file>for_fun.sh</file><!--添加这行--> <capture-output/> </shell>
问题2:在shell脚本里面运行sqoop命令,却出错: com.cloudera.sqoop.tool.ImportTool: Encountered IOException running import job: java.io.IOException: The ownership on the staging directory hdfs://pangu-hdpnn.dscc:11000/mapred/staging/jiyaodian/.staging is not as expected. It is owned by jiyaodian. The directory must be owned by the submitter work or by work。 解决方法:未知
转载请注明: 转载自http://jyd.me/
本文链接地址: Oozie运行Shell的一些问题
- ubuntu eclispe 缩进不正常
- Oozie 出现 ClassNotFoundException 解决方法