从shell脚本触发oozie

时间:2014-02-27 12:45:28

标签: shell cron crontab oozie

我正在尝试运行包含oozie作业的shell脚本;从crontab触发此shell脚本。 Oozie没有被触发!!!

shell脚本myshell.sh包含

#!/bin/bash
oozie  job -run -config $1

的crontab

*/5 * * * * /path/myshell.sh example.properties

我需要在我的环境中设置一些东西,还是我遗漏了一些东西!

由于

1 个答案:

答案 0 :(得分:2)

看起来你错过了-oozie参数来指定oozie api url。

oozie job -oozie http://ooziehost:11000/oozie -run -config $1

您也可以设置OOZIE_URL环境变量

#!/bin/bash
OOZIE_URL=http://ooziehost:11000/oozie
oozie job -run -config $1