Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-29

In Datanode, update block may fail due to length inconsistency

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.21.0
    • Component/s: datanode
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      When a primary datanode tries to recover a block. It calls getBlockMetaDataInfo(..) to obtains information like block length from each datanode. Then, it calls updateBlock(..).

      The block length returned in getBlockMetaDataInfo(..) may be obtained from a unclosed local block file F. However, in updateBlock(..), it first closes F (if F is open) and then gets the length. These two lengths may be different. In such case, updateBlock(..) throws an exception.

        Attachments

        1. h29_20091012c.patch
          7 kB
          Tsz Wo Nicholas Sze
        2. h29_20091012b.patch
          7 kB
          Tsz Wo Nicholas Sze
        3. h29_20091012.patch
          4 kB
          Tsz Wo Nicholas Sze

          Issue Links

            Activity

              People

              • Assignee:
                szetszwo Tsz Wo Nicholas Sze
                Reporter:
                szetszwo Tsz Wo Nicholas Sze
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: