title: How to copy data from HDFS to Local FS using oozie workflow?
body: <p>I have written the java code using <code>FileUtil.CopyMerge(…)</code> to merge the files into single file.</p>
  
  <p>Below is my oozie java action :</p>
  
  <pre><code>&lt;main-class&gt;Merging&lt;/main-class
  &lt;arg&gt;${nameNode}/user/abhime01/haadoop/Merge/merge_output&lt;/arg&gt;
  &lt;arg&gt;file:///home/abhi01/yoooize.txt&lt;/arg&gt;
  </code></pre>
  
  <p>In the above workflow if I try the second <code>arg(destination)</code> as a path in hdfs I am able to merge the data and store in hdfs.</p>
  
  <p>But if I give it as path in local file system(as in above snippet) I am getting the following error :</p>
  
  <blockquote>
    <p>Mkdirs failed to create file:/home/abhime01 (exists=false,
    cwd=file:/CDH/sdu1/yarn/nm/usercache/abhime01/appcache/application_1440579785423_1755/container_e27_1440579785423_1755_01_000001)</p>
  </blockquote>
  
  <p>Can anyone please suggest me how to merge files and store it into local FS using ooize.</p>
  
  <p>PS: Java code works fine if it is run without oozie, problem exists while running through oozie.</p>