[
https://issues.apache.org/jira/browse/HDFS-5982?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13907235#comment-13907235
]
Chris Nauroth commented on HDFS-5982:
-------------------------------------
Nice find, Tassapol and Jing. The patch mostly looks good to me, after we fix
the unit test failure.
One question: {{unprotectedDelete}} formerly checked for {{deleteAllowed}}. Is
that check no longer required?
> Need to update snapshot manager when applying editlog for deleting a
> snapshottable directory
> --------------------------------------------------------------------------------------------
>
> Key: HDFS-5982
> URL: https://issues.apache.org/jira/browse/HDFS-5982
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: namenode
> Affects Versions: 2.3.0
> Reporter: Tassapol Athiapinya
> Assignee: Jing Zhao
> Priority: Critical
> Attachments: HDFS-5982.000.patch
>
>
> Currently after deleting a snapshottable directory which does not have
> snapshots any more, we also remove the directory from the snapshottable
> directory list in SnapshotManager. This works fine when handling a delete
> request from user. However, when we apply the OP_DELETE editlog,
> FSDirectory#unprotectedDelete(String, long) is called, which does not contain
> the "updating snapshot manager" process. This may leave an non-existent inode
> id in the snapshottable directory list, and can even lead to FSImage
> corruption.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)