Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-15477 Enforce ordered snapshot deletion
  3. HDFS-15492

Make trash root inside each snapshottable directory

Log workAgile BoardRank to TopRank to BottomAttach filesAttach ScreenshotBulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersConvert to IssueMoveLinkCloneLabelsUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Reviewed

    Description

      We have seen FSImage corruption cases (e.g. HDFS-13101) where files inside one snapshottable directories are moved outside of it. The most common case of this is when trash is enabled and user deletes some file via the command line without skipTrash.

      This jira aims to make a trash root for each snapshottable directory, same as how encryption zone behaves at the moment.

      This will make trash cleanup a little bit more expensive on the NameNode as it will be to iterate all trash roots. But should be fine as long as there aren't many snapshottable directories.

      I could make this improvement as an option and disable it by default if needed, such as dfs.namenode.snapshot.trashroot.enabled

      One small caveat though, when disabling (disallowing) snapshot on the snapshottable directory when this improvement is in place. The client should merge the snapshottable directory's trash with that user's trash to ensure proper trash cleanup.

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            smeng Siyao Meng Assign to me
            smeng Siyao Meng
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - Not Specified
              Not Specified
              Remaining:
              Remaining Estimate - 0h
              0h
              Logged:
              Time Spent - 0.5h
              0.5h

              Slack

                Issue deployment