Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-2934

NPE while loading FSImage

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.17.0
    • 0.17.0
    • None
    • None

    Description

      André Martin reported on core-user mailing list :

       
      [...]
      2008-03-02 01:25:29,887 ERROR org.apache.hadoop.dfs.NameNode: java.lang.NullPointerException
          at org.apache.hadoop.dfs.FSImage.readINodeUnderConstruction(FSImage.java:950)
          at org.apache.hadoop.dfs.FSImage.loadFilesUnderConstruction(FSImage.java:919)
          at org.apache.hadoop.dfs.FSImage.loadFSImage(FSImage.java:749)
          at org.apache.hadoop.dfs.FSImage.loadFSImage(FSImage.java:634)
          at org.apache.hadoop.dfs.FSImage.recoverTransitionRead(FSImage.java:223)
          at org.apache.hadoop.dfs.FSDirectory.loadFSImage(FSDirectory.java:79)
          at org.apache.hadoop.dfs.FSNamesystem.initialize(FSNamesystem.java:261)
          at org.apache.hadoop.dfs.FSNamesystem.<init>(FSNamesystem.java:242)
          at org.apache.hadoop.dfs.NameNode.initialize(NameNode.java:131)
          at org.apache.hadoop.dfs.NameNode.<init>(NameNode.java:176)
          at org.apache.hadoop.dfs.NameNode.<init>(NameNode.java:162)
          at org.apache.hadoop.dfs.NameNode.createNameNode(NameNode.java:851)
          at org.apache.hadoop.dfs.NameNode.main(NameNode.java:860)
      

      Block object should be allocated before calling readFields() in FSImage.java :

      BlockInfo[] blocks = new BlockInfo[numBlocks];
      for (int i = 0; i < numBlocks; i++) {
        blocks[i].readFields(in);
      }
      

      Attachments

        1. NPE_FSImage.patch
          1 kB
          Dhruba Borthakur
        2. NPE_FSImage.patch
          0.7 kB
          Dhruba Borthakur
        3. NPE_FSImage.patch
          1.0 kB
          Dhruba Borthakur

        Activity

          People

            dhruba Dhruba Borthakur
            rangadi Raghu Angadi
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: