Support Questions
Find answers, ask questions, and share your expertise
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

How to execute the workflow.xml in oozie?

How to execute the workflow.xml in oozie?



I am new to oozie  try to creating a workflow using pigscript and executing it. I don't have clear idea of executing the workflow.


My workflow sample is:


<workflow-app name="FirstWorkFlow" xmlns="uri:oozie:workflow:0.2">
<start to="FirstJob"/>
<action name="FirstJob">
<ok to="end"/>
<error to="kill"/>
<kill name="kill">
<message>Action failed, error message[${wf:errorMessage(wf:lastErrorNode())}]</message>
<end name="end" />



and my pigscript is:


A = load 'example.csv' using PigStorage(',') as (FILENAME,FILEDATE,SOURCETYPE)


when i ran the commnd in the following box this was the error which prompted :


java.lang.RuntimeException: bad conf file: top-level element not <configuration>
at org.apache.oozie.cli.OozieCLI.parseDocument(
at org.apache.oozie.cli.OozieCLI.parse(
at org.apache.oozie.cli.OozieCLI.getConfiguration(
at org.apache.oozie.cli.OozieCLI.jobCommand(
at org.apache.oozie.cli.OozieCLI.processCommand(
at org.apache.oozie.cli.OozieCLI.main(
bad conf file: top-level element not <configuration>


can anyone solve this Thanks in advance



oozie job -oozie http://localhost:11000/oozie -config workflow.xml -submit

Re: How to execute the workflow.xml in oozie?

Master Guru
Please follow this example Oozie tutorial to understand how Oozie and submissions to it work:

The specific error in your execution is cause of passing the workflow XML as a -config file. This is incorrect.
Don't have an account?
Coming from Hortonworks? Activate your account here