Hadoop HDFS
  1. Hadoop HDFS
  2. HDFS-622

checkMinReplication should count only live node.

    Details

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

      Description

      BlockManager.checkMinReplication(Block) currently counts all replicas of the block even if they are corrupt. Corrupt replicas should be excluded.

      1. liveReplicas.patch
        0.6 kB
        Konstantin Shvachko

        Activity

        Konstantin Shvachko created issue -
        Hide
        Konstantin Shvachko added a comment -

        Here is a simple patch which replaces
        blocksMap.numNodes(block) >= minReplication
        with
        countNodes(block).liveReplicas() >= minReplication

        Show
        Konstantin Shvachko added a comment - Here is a simple patch which replaces blocksMap.numNodes(block) >= minReplication with countNodes(block).liveReplicas() >= minReplication
        Konstantin Shvachko made changes -
        Field Original Value New Value
        Attachment liveReplicas.patch [ 12419717 ]
        Konstantin Shvachko made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Hide
        Hadoop QA added a comment -

        +1 overall. Here are the results of testing the latest attachment
        http://issues.apache.org/jira/secure/attachment/12419717/liveReplicas.patch
        against trunk revision 815496.

        +1 @author. The patch does not contain any @author tags.

        -1 tests included. The patch doesn't appear to include any new or modified tests.
        Please justify why no new tests are needed for this patch.
        Also please list what manual steps were performed to verify this patch.

        +1 javadoc. The javadoc tool did not generate any warning messages.

        +1 javac. The applied patch does not increase the total number of javac compiler warnings.

        +1 findbugs. The patch does not introduce any new Findbugs warnings.

        +1 release audit. The applied patch does not increase the total number of release audit warnings.

        +1 core tests. The patch passed core unit tests.

        +1 contrib tests. The patch passed contrib unit tests.

        Test results: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/testReport/
        Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
        Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/artifact/trunk/build/test/checkstyle-errors.html
        Console output: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/console

        This message is automatically generated.

        Show
        Hadoop QA added a comment - +1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12419717/liveReplicas.patch against trunk revision 815496. +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/testReport/ Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/artifact/trunk/build/test/checkstyle-errors.html Console output: http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/31/console This message is automatically generated.
        Hide
        Boris Shkolnik added a comment -

        +1

        Note. No test - I assume it is covered by some of the exiting tests.

        Show
        Boris Shkolnik added a comment - +1 Note. No test - I assume it is covered by some of the exiting tests.
        Hide
        Konstantin Shvachko added a comment -

        > No test - I assume it is covered by some of the exiting tests.

        True, TestFileCreation is one of them.

        Show
        Konstantin Shvachko added a comment - > No test - I assume it is covered by some of the exiting tests. True, TestFileCreation is one of them.
        Hide
        Konstantin Shvachko added a comment -

        I just committed this.

        Show
        Konstantin Shvachko added a comment - I just committed this.
        Konstantin Shvachko made changes -
        Status Patch Available [ 10002 ] Resolved [ 5 ]
        Hadoop Flags [Reviewed]
        Resolution Fixed [ 1 ]
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Hdfs-trunk-Commit #38 (See http://hudson.zones.apache.org/hudson/job/Hadoop-Hdfs-trunk-Commit/38/)
        . checkMinReplication should count live nodes only. Contributed by Konstantin Shvachko.

        Show
        Hudson added a comment - Integrated in Hadoop-Hdfs-trunk-Commit #38 (See http://hudson.zones.apache.org/hudson/job/Hadoop-Hdfs-trunk-Commit/38/ ) . checkMinReplication should count live nodes only. Contributed by Konstantin Shvachko.
        Hide
        Hudson added a comment -

        Integrated in Hadoop-Hdfs-trunk #86 (See http://hudson.zones.apache.org/hudson/job/Hadoop-Hdfs-trunk/86/)
        . checkMinReplication should count live nodes only. Contributed by Konstantin Shvachko.

        Show
        Hudson added a comment - Integrated in Hadoop-Hdfs-trunk #86 (See http://hudson.zones.apache.org/hudson/job/Hadoop-Hdfs-trunk/86/ ) . checkMinReplication should count live nodes only. Contributed by Konstantin Shvachko.
        Hide
        Hudson added a comment -

        Integrated in Hdfs-Patch-h5.grid.sp2.yahoo.net #35 (See http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/35/)

        Show
        Hudson added a comment - Integrated in Hdfs-Patch-h5.grid.sp2.yahoo.net #35 (See http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h5.grid.sp2.yahoo.net/35/ )
        Hide
        Hudson added a comment -

        Integrated in Hdfs-Patch-h2.grid.sp2.yahoo.net #11 (See http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h2.grid.sp2.yahoo.net/11/)

        Show
        Hudson added a comment - Integrated in Hdfs-Patch-h2.grid.sp2.yahoo.net #11 (See http://hudson.zones.apache.org/hudson/job/Hdfs-Patch-h2.grid.sp2.yahoo.net/11/ )
        Tom White made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Konstantin Shvachko
            Reporter:
            Konstantin Shvachko
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development