You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Kihwal Lee (JIRA)" <ji...@apache.org> on 2015/08/18 20:08:45 UTC

[jira] [Commented] (HDFS-8863) The remaining space check in BlockPlacementPolicyDefault is flawed

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

Kihwal Lee commented on HDFS-8863:
----------------------------------

bq. I am thinking we can do as following: do storage type level sum, but for each storage, we only count the remaining space of multiple block size part...
That sounds like a better idea.

bq. So I think you can do these check in getRemaining.
I think that is reasonable thing to do in this patch. 

> The remaining space check in BlockPlacementPolicyDefault is flawed
> ------------------------------------------------------------------
>
>                 Key: HDFS-8863
>                 URL: https://issues.apache.org/jira/browse/HDFS-8863
>             Project: Hadoop HDFS
>          Issue Type: Bug
>    Affects Versions: 2.6.0
>            Reporter: Kihwal Lee
>            Assignee: Kihwal Lee
>            Priority: Critical
>              Labels: 2.6.1-candidate
>         Attachments: HDFS-8863.patch, HDFS-8863.v2.patch
>
>
> The block placement policy calls {{DatanodeDescriptor#getRemaining(StorageType}}}} to check whether the block is going to fit. Since the method is adding up all remaining spaces, namenode can allocate a new block on a full node. This causes pipeline construction failure and {{abandonBlock}}. If the cluster is nearly full, the client might hit this multiple times and the write can fail permanently.



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