hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "surendra singh lilhore (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-8296) BlockManager.getUnderReplicatedBlocksCount() is not giving correct count if namenode in safe mode.
Date Wed, 06 May 2015 14:01:16 GMT

    [ https://issues.apache.org/jira/browse/HDFS-8296?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14530585#comment-14530585
] 

surendra singh lilhore commented on HDFS-8296:
----------------------------------------------

bq. BlockManager.java:1: File length is 3,821 lines (max allowed is 2,000).

Checkstyle is because of file length...

>  BlockManager.getUnderReplicatedBlocksCount() is not giving correct count if namenode
in safe mode.
> ---------------------------------------------------------------------------------------------------
>
>                 Key: HDFS-8296
>                 URL: https://issues.apache.org/jira/browse/HDFS-8296
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: namenode
>    Affects Versions: 2.6.0
>            Reporter: surendra singh lilhore
>            Assignee: surendra singh lilhore
>              Labels: BB2015-05-TBR
>         Attachments: HDFS-8296.patch
>
>
> {{underReplicatedBlocksCount}} update by the {{updateState()}} API.
> {code}
>  void updateState() {
>     pendingReplicationBlocksCount = pendingReplications.size();
>     underReplicatedBlocksCount = neededReplications.size();
>     corruptReplicaBlocksCount = corruptReplicas.size();
>   }
>  {code}
>  but this will not call when NN in safe mode. This is happening because "computeDatanodeWork()"
we will return 0 if NN in safe mode 
>  {code}
>   int computeDatanodeWork() {
>    .........
>     if (namesystem.isInSafeMode()) {
>       return 0;
>     }
>     ....................
>     ....................
>     this.updateState();
>     ....................
>     ....................
>   }
>  {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message