當一個oozie job運行失敗後可以使用rerun參數重跑job
由於我的oozie版本比較舊,文檔中是這樣說的
- oozie.wf.application.path
- oozie.wf.rerun.skip.nodes
- Above two are mandatory configs.
- Skip nodes are comma separated list of action names. They can be any action nodes including decision node.
網上找了一圈,沒發現有用的資料,最後由高人指點,原來是將oozie job管理界面中的Job Configuration內容拷貝到新建的xml中間中
然後在這個xml中新加一個property,如下
<property>
<name>oozie.wf.rerun.skip.nodes</name>
<value>action1,action2</value>
</property>
value爲需要跳過的action名
rerun 命令:oozie job -rerun job_id -config rerun.xml
依舊報錯:Error: E0301 : E0301: Invalid resource [hdfs://localhost/workflow.xml]
找到這篇blog點擊打開鏈接
此博主說是因爲wf的配置文件和coord的配置文件不能同時存在,oozie中的代碼
protected static void ValidateAppPath(String wfPath, String coordPath) throws XServletException {
if (wfPath != null && coordPath != null) {
throw new XServletException(HttpServletResponse.SC_BAD_REQUEST, ErrorCode.E0301, wfPath, coordPath);
}
else {
if (wfPath == null && coordPath == null) {
throw new XServletException(HttpServletResponse.SC_BAD_REQUEST, ErrorCode.E0302);
}
}
}
按照博主所說刪掉xml中的oozie.wf.application.path,運行後依然報錯,找不到workflow.xml
workflow.xml中存放的是我要運行的工作流,怎麼可以刪除呢,懷疑是否是因爲此博主的job是定時工作流,所以把工作流配置參數都寫在了coord.xml中
而我的工作流還是在workflow.xml,所以我應該刪除oozie.coord.application.path
再次運行成功!