Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-13201

Print the directory paths when ViewFs denies the rename operation on internal dirs

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.7.2
    • Fix Version/s: 2.8.0, 2.7.4, 3.0.0-alpha2
    • Component/s: viewfs
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      With ViewFs, the delete and rename operations on internal dirs are denied by throwing AccessControlException.

      Unlike the delete() which notify the internal dir path, rename does not.

      The attached patch appends the directory path on the logged exception.

      ViewFs.java
           InodeTree.ResolveResult<AbstractFileSystem> resSrc = 
             fsState.resolve(getUriPath(src), false); 
           if (resSrc.isInternalDir()) {
             throw new AccessControlException(
      -          "Cannot Rename within internal dirs of mount table: it is readOnly");
      +          "Cannot Rename within internal dirs of mount table: it is readOnly"
      +          + src);
           }
             
           InodeTree.ResolveResult<AbstractFileSystem> resDst = 
                                       fsState.resolve(getUriPath(dst), false);
           if (resDst.isInternalDir()) {
             throw new AccessControlException(
      -          "Cannot Rename within internal dirs of mount table: it is readOnly");
      +          "Cannot Rename within internal dirs of mount table: it is readOnly"
      +          + dst);
           }
      
      1. HADOOP-13201.000.patch
        1 kB
        Tianyin Xu
      2. HADOOP-13201-001.patch
        2 kB
        Rakesh R

        Activity

        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #10706 (See https://builds.apache.org/job/Hadoop-trunk-Commit/10706/)
        HADOOP-13201. Print the directory paths when ViewFs denies the rename (brahma: rev 0c837db8a874079dd5db83a7eef9c4d2b9d0e9ff)

        • (edit) hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/viewfs/ViewFs.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #10706 (See https://builds.apache.org/job/Hadoop-trunk-Commit/10706/ ) HADOOP-13201 . Print the directory paths when ViewFs denies the rename (brahma: rev 0c837db8a874079dd5db83a7eef9c4d2b9d0e9ff) (edit) hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/viewfs/ViewFs.java
        Hide
        brahmareddy Brahma Reddy Battula added a comment -

        Committed to trunk,branch-2,branch-2.8 and branch-2.7..Tianyin Xu thanks for reporting and contributing and thanks to Rakesh R for rebasing the patch.

        Show
        brahmareddy Brahma Reddy Battula added a comment - Committed to trunk,branch-2,branch-2.8 and branch-2.7.. Tianyin Xu thanks for reporting and contributing and thanks to Rakesh R for rebasing the patch.
        Hide
        rakeshr Rakesh R added a comment -
        Show
        rakeshr Rakesh R added a comment - Thank you Brahma Reddy Battula
        Hide
        brahmareddy Brahma Reddy Battula added a comment -

        Rakesh R thanks for rebasing the patch.. +1, will commit soon.

        Show
        brahmareddy Brahma Reddy Battula added a comment - Rakesh R thanks for rebasing the patch.. +1, will commit soon.
        Hide
        rakeshr Rakesh R added a comment -
        Show
        rakeshr Rakesh R added a comment - cc/ Vinayakumar B
        Hide
        rakeshr Rakesh R added a comment -

        Kindly review the patch. Thanks!

        Show
        rakeshr Rakesh R added a comment - Kindly review the patch. Thanks!
        Hide
        hadoopqa Hadoop QA added a comment -
        -1 overall



        Vote Subsystem Runtime Comment
        0 reexec 0m 16s Docker mode activated.
        +1 @author 0m 0s The patch does not contain any @author tags.
        -1 test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
        +1 mvninstall 6m 41s trunk passed
        +1 compile 6m 59s trunk passed
        +1 checkstyle 0m 24s trunk passed
        +1 mvnsite 1m 0s trunk passed
        +1 mvneclipse 0m 13s trunk passed
        +1 findbugs 1m 28s trunk passed
        +1 javadoc 0m 41s trunk passed
        +1 mvninstall 0m 37s the patch passed
        +1 compile 6m 52s the patch passed
        +1 javac 6m 52s the patch passed
        +1 checkstyle 0m 23s the patch passed
        +1 mvnsite 0m 54s the patch passed
        +1 mvneclipse 0m 12s the patch passed
        +1 whitespace 0m 0s The patch has no whitespace issues.
        +1 findbugs 1m 29s the patch passed
        +1 javadoc 0m 42s the patch passed
        +1 unit 8m 48s hadoop-common in the patch passed.
        +1 asflicense 0m 21s The patch does not generate ASF License warnings.
        39m 22s



        Subsystem Report/Notes
        Docker Image:yetus/hadoop:9560f25
        JIRA Issue HADOOP-13201
        JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12835517/HADOOP-13201-001.patch
        Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle
        uname Linux 42664ce607db 3.13.0-36-lowlatency #63-Ubuntu SMP PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
        Build tool maven
        Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh
        git revision trunk / 6cc7c43
        Default Java 1.8.0_101
        findbugs v3.0.0
        Test Results https://builds.apache.org/job/PreCommit-HADOOP-Build/10907/testReport/
        modules C: hadoop-common-project/hadoop-common U: hadoop-common-project/hadoop-common
        Console output https://builds.apache.org/job/PreCommit-HADOOP-Build/10907/console
        Powered by Apache Yetus 0.4.0-SNAPSHOT http://yetus.apache.org

        This message was automatically generated.

        Show
        hadoopqa Hadoop QA added a comment - -1 overall Vote Subsystem Runtime Comment 0 reexec 0m 16s Docker mode activated. +1 @author 0m 0s The patch does not contain any @author tags. -1 test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 mvninstall 6m 41s trunk passed +1 compile 6m 59s trunk passed +1 checkstyle 0m 24s trunk passed +1 mvnsite 1m 0s trunk passed +1 mvneclipse 0m 13s trunk passed +1 findbugs 1m 28s trunk passed +1 javadoc 0m 41s trunk passed +1 mvninstall 0m 37s the patch passed +1 compile 6m 52s the patch passed +1 javac 6m 52s the patch passed +1 checkstyle 0m 23s the patch passed +1 mvnsite 0m 54s the patch passed +1 mvneclipse 0m 12s the patch passed +1 whitespace 0m 0s The patch has no whitespace issues. +1 findbugs 1m 29s the patch passed +1 javadoc 0m 42s the patch passed +1 unit 8m 48s hadoop-common in the patch passed. +1 asflicense 0m 21s The patch does not generate ASF License warnings. 39m 22s Subsystem Report/Notes Docker Image:yetus/hadoop:9560f25 JIRA Issue HADOOP-13201 JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12835517/HADOOP-13201-001.patch Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle uname Linux 42664ce607db 3.13.0-36-lowlatency #63-Ubuntu SMP PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux Build tool maven Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh git revision trunk / 6cc7c43 Default Java 1.8.0_101 findbugs v3.0.0 Test Results https://builds.apache.org/job/PreCommit-HADOOP-Build/10907/testReport/ modules C: hadoop-common-project/hadoop-common U: hadoop-common-project/hadoop-common Console output https://builds.apache.org/job/PreCommit-HADOOP-Build/10907/console Powered by Apache Yetus 0.4.0-SNAPSHOT http://yetus.apache.org This message was automatically generated.
        Hide
        rakeshr Rakesh R added a comment -

        Thanks Tianyin Xu for reporting this. I've modified the exception message and placed src and dest properly, please review this.

        Show
        rakeshr Rakesh R added a comment - Thanks Tianyin Xu for reporting this. I've modified the exception message and placed src and dest properly, please review this.
        Hide
        hadoopqa Hadoop QA added a comment -
        -1 overall



        Vote Subsystem Runtime Comment
        0 reexec 0m 12s Docker mode activated.
        +1 @author 0m 0s The patch does not contain any @author tags.
        -1 test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch.
        +1 mvninstall 7m 30s trunk passed
        +1 compile 7m 29s trunk passed
        +1 checkstyle 0m 28s trunk passed
        +1 mvnsite 1m 7s trunk passed
        +1 mvneclipse 0m 13s trunk passed
        +1 findbugs 1m 29s trunk passed
        +1 javadoc 1m 1s trunk passed
        +1 mvninstall 0m 42s the patch passed
        +1 compile 6m 31s the patch passed
        +1 javac 6m 31s the patch passed
        +1 checkstyle 0m 22s the patch passed
        +1 mvnsite 0m 56s the patch passed
        +1 mvneclipse 0m 11s the patch passed
        +1 whitespace 0m 0s The patch has no whitespace issues.
        +1 findbugs 1m 32s the patch passed
        +1 javadoc 0m 53s the patch passed
        +1 unit 7m 50s hadoop-common in the patch passed.
        +1 asflicense 0m 20s The patch does not generate ASF License warnings.
        39m 29s



        Subsystem Report/Notes
        Docker Image:yetus/hadoop:2c91fd8
        JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12806009/HADOOP-13201.000.patch
        JIRA Issue HADOOP-13201
        Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle
        uname Linux 8a6c6112300d 3.13.0-36-lowlatency #63-Ubuntu SMP PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
        Build tool maven
        Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh
        git revision trunk / edd716e
        Default Java 1.8.0_91
        findbugs v3.0.0
        Test Results https://builds.apache.org/job/PreCommit-HADOOP-Build/9572/testReport/
        modules C: hadoop-common-project/hadoop-common U: hadoop-common-project/hadoop-common
        Console output https://builds.apache.org/job/PreCommit-HADOOP-Build/9572/console
        Powered by Apache Yetus 0.4.0-SNAPSHOT http://yetus.apache.org

        This message was automatically generated.

        Show
        hadoopqa Hadoop QA added a comment - -1 overall Vote Subsystem Runtime Comment 0 reexec 0m 12s Docker mode activated. +1 @author 0m 0s The patch does not contain any @author tags. -1 test4tests 0m 0s The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. +1 mvninstall 7m 30s trunk passed +1 compile 7m 29s trunk passed +1 checkstyle 0m 28s trunk passed +1 mvnsite 1m 7s trunk passed +1 mvneclipse 0m 13s trunk passed +1 findbugs 1m 29s trunk passed +1 javadoc 1m 1s trunk passed +1 mvninstall 0m 42s the patch passed +1 compile 6m 31s the patch passed +1 javac 6m 31s the patch passed +1 checkstyle 0m 22s the patch passed +1 mvnsite 0m 56s the patch passed +1 mvneclipse 0m 11s the patch passed +1 whitespace 0m 0s The patch has no whitespace issues. +1 findbugs 1m 32s the patch passed +1 javadoc 0m 53s the patch passed +1 unit 7m 50s hadoop-common in the patch passed. +1 asflicense 0m 20s The patch does not generate ASF License warnings. 39m 29s Subsystem Report/Notes Docker Image:yetus/hadoop:2c91fd8 JIRA Patch URL https://issues.apache.org/jira/secure/attachment/12806009/HADOOP-13201.000.patch JIRA Issue HADOOP-13201 Optional Tests asflicense compile javac javadoc mvninstall mvnsite unit findbugs checkstyle uname Linux 8a6c6112300d 3.13.0-36-lowlatency #63-Ubuntu SMP PREEMPT Wed Sep 3 21:56:12 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux Build tool maven Personality /testptch/hadoop/patchprocess/precommit/personality/provided.sh git revision trunk / edd716e Default Java 1.8.0_91 findbugs v3.0.0 Test Results https://builds.apache.org/job/PreCommit-HADOOP-Build/9572/testReport/ modules C: hadoop-common-project/hadoop-common U: hadoop-common-project/hadoop-common Console output https://builds.apache.org/job/PreCommit-HADOOP-Build/9572/console Powered by Apache Yetus 0.4.0-SNAPSHOT http://yetus.apache.org This message was automatically generated.

          People

          • Assignee:
            rakeshr Rakesh R
            Reporter:
            tianyin Tianyin Xu
          • Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development