Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-5021

FSShell delete and FSShell rename should operate on symlinks, not their targets

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • None
    • 2.1.0-beta
    • None
    • None

    Description

      Currently FSShell delete and FSShell rename don't behave as expected on symlinks. If you have /a/b/c as a link to /a/b/d, and you try to delete /a/b/c, the target /a/b/d will be deleted instead. Not only is this contrary to POSIX (and pretty much every other filesystem standard) but this gives us no way to actually delete symlinks other than deleting the containing directory.

      Let's fix this so deleting a symlink deletes the symlink itself. It will just require not dereferencing the last path component. I haven't looked as closely into rename but I think there are similar issues there

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              cmccabe Colin McCabe
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: