title: Content of FSIMAGE and EDIT files in Hadoop command error
body: <p>I am using Hadoop 2.2.0 version. I want to see the content of &quot;FSIMAGE&quot; and &quot;EDITS&quot; files. i used following command:</p>
  <blockquote>
  <p>bin/hdfs oiv -i fsimage -o fsimage.txt</p>
  <p>bin/hdfs oev -i edits -o edits.xml</p>
  </blockquote>
  <p>I came to know about these commands from <a href="http://hadoop.apache.org/docs/stable/hadoop-project-dist/hadoop-hdfs/HdfsImageViewer.html" rel="nofollow noreferrer">Aapche hadoop site documentation</a>. I ran sample word count program and after this tried above command and got this:-</p>
  <pre><code>rushi@ubuntu:/usr/local/hadoop$ bin/hdfs oiv -i fsimage -o fsimage.xml -p XML
  Exception in thread &quot;main&quot; java.lang.NullPointerException
      at org.apache.hadoop.hdfs.tools.offlineImageViewer.OfflineImageViewer.go(OfflineImageViewer.java:140)
      at org.apache.hadoop.hdfs.tools.offlineImageViewer.OfflineImageViewer.main(OfflineImageViewer.java:260)
  </code></pre>
  <p>&quot;fsimage.xml&quot; file created but it is EMPTY.</p>
  <p>What may be the problem or how can i see the content of these files ?</p>