[
https://issues.apache.org/jira/browse/HDFS-4735?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jing Zhao updated HDFS-4735:
----------------------------
Attachment: HDFS-4735.000.patch
When we have nested snapshottable directories and if we try to reset the
snapshottable descendant back to an regular directory, we need to replace the
snapshottable descendant with an INodeDirectoryWithSnapshot. In this case, we
should not do the preconditions check in
INodeDirectory#replaceSelf4INodeDirectoryWithSnapshot.
Upload a simple fix first. Will add a unit test later.
> DisallowSnapshot throws IllegalStateException
> ---------------------------------------------
>
> Key: HDFS-4735
> URL: https://issues.apache.org/jira/browse/HDFS-4735
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Components: namenode
> Reporter: Ramya Sunil
> Assignee: Jing Zhao
> Fix For: Snapshot (HDFS-2802)
>
> Attachments: HDFS-4735.000.patch
>
>
> After a long running stress test for snapshots, disallow snapshot throws
> IllegalStateException
> -bash-4.1$ hadoop dfs -rmr -skipTrash /user/foo/hdfs-snapshots
> rmr: cannot remove /user/foo/hdfs-snapshots: No such file or directory.
> -bash-4.1$ /usr/lib/hadoop/bin/hadoop dfs -mkdir
> /user/foo/hdfs-snapshots/test2
> -bash-4.1$ /usr/lib/hadoop/bin/hadoop dfsadmin -allowSnapshot
> /user/foo/hdfs-snapshots/test2
> Allowing snaphot on /user/foo/hdfs-snapshots/test2 succeeded
> -bash-4.1$ /usr/lib/hadoop/bin/hadoop dfsadmin -disallowSnapshot
> /user/foo/hdfs-snapshots/test2
> disallowSnapshot: java.io.IOException: java.lang.IllegalStateException: this
> is already an INodeDirectoryWithSnapshot, this=test2
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira