Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-14603 Über-JIRA: HDFS RBF stabilization phase II
  3. HDFS-14117

RBF: We can only delete the files or dirs of one subcluster in a cluster with multiple subclusters when trash is enabled

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Patch Available
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None

    Description

      When we delete files or dirs in hdfs, it will move the deleted files or dirs to trash by default.

      But in the global path we can only mount one trash dir /user. So we mount trash dir /user of the subcluster ns1 to the global path /user. Then we can delete files or dirs of ns1, but when we delete the files or dirs of another subcluser, such as hacluster, it will be failed.

      Mount Table

      Global path Target nameservice Target path Order Read only Owner Group Permission Quota/Usage Date Modified Date Created
      /test hacluster2 /test     securedn users rwxr-xr-x [NsQuota: -/-, SsQuota: -/-] 2018/11/29 14:37:42 2018/11/29 14:37:42
      /tmp hacluster1 /tmp     securedn users rwxr-xr-x [NsQuota: -/-, SsQuota: -/-] 2018/11/29 14:37:05 2018/11/29 14:37:05
      /user hacluster2,hacluster1 /user HASH   securedn users rwxr-xr-x [NsQuota: -/-, SsQuota: -/-] 2018/11/29 14:42:37 2018/11/29 14:38:20

      commands: 

      1./opt/HAcluater_ram1/install/hadoop/router/bin> ./hdfs dfs -ls /test/.
      18/11/30 11:00:47 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
      Found 1 items
      -rw-r--r-- 3 securedn supergroup 8081 2018-11-30 10:56 /test/hdfs.cmd
      
      2./opt/HAcluater_ram1/install/hadoop/router/bin> ./hdfs dfs -ls /tmp/.
      18/11/30 11:00:40 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
      Found 1 items
      -rw-r--r--   3 securedn supergroup       6311 2018-11-30 10:57 /tmp/mapred.cmd
      
      3../opt/HAcluater_ram1/install/hadoop/router/bin> ./hdfs dfs -rm /tmp/mapred.cmd
      18/11/30 11:01:02 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
      rm: Failed to move to trash: hdfs://router/tmp/mapred.cmd: rename destination parent /user/securedn/.Trash/Current/tmp/mapred.cmd not found.
      
      4./opt/HAcluater_ram1/install/hadoop/router/bin> ./hdfs dfs -rm /test/hdfs.cmd
      18/11/30 11:01:20 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
      18/11/30 11:01:22 INFO fs.TrashPolicyDefault: Moved: 'hdfs://router/test/hdfs.cmd' to trash at: hdfs://router/user/securedn/.Trash/Current/test/hdfs.cmd
      

      Attachments

        1. HDFS-14117.001.patch
          10 kB
          Ramkumar Ramalingam
        2. HDFS-14117.002.patch
          10 kB
          Ramkumar Ramalingam
        3. HDFS-14117.003.patch
          8 kB
          Ramkumar Ramalingam
        4. HDFS-14117.004.patch
          9 kB
          Ramkumar Ramalingam
        5. HDFS-14117.005.patch
          8 kB
          Ramkumar Ramalingam
        6. HDFS-14117-HDFS-13891.001.patch
          9 kB
          Ramkumar Ramalingam
        7. HDFS-14117-HDFS-13891.002.patch
          9 kB
          Ramkumar Ramalingam
        8. HDFS-14117-HDFS-13891.003.patch
          7 kB
          Ramkumar Ramalingam
        9. HDFS-14117-HDFS-13891.004.patch
          9 kB
          Ramkumar Ramalingam
        10. HDFS-14117-HDFS-13891.005.patch
          9 kB
          Ramkumar Ramalingam
        11. HDFS-14117-HDFS-13891.006.patch
          9 kB
          Ramkumar Ramalingam
        12. HDFS-14117-HDFS-13891.007.patch
          9 kB
          Ramkumar Ramalingam
        13. HDFS-14117-HDFS-13891.008.patch
          9 kB
          Ramkumar Ramalingam
        14. HDFS-14117-HDFS-13891.009.patch
          13 kB
          Íñigo Goiri
        15. HDFS-14117-HDFS-13891.010.patch
          14 kB
          Íñigo Goiri
        16. HDFS-14117-HDFS-13891.011.patch
          24 kB
          Íñigo Goiri
        17. HDFS-14117-HDFS-13891.012.patch
          27 kB
          Íñigo Goiri
        18. HDFS-14117-HDFS-13891.013.patch
          47 kB
          Íñigo Goiri
        19. HDFS-14117-HDFS-13891.014.patch
          51 kB
          Íñigo Goiri
        20. HDFS-14117-HDFS-13891.015.patch
          52 kB
          Íñigo Goiri
        21. HDFS-14117-HDFS-13891.016.patch
          53 kB
          Íñigo Goiri
        22. HDFS-14117-HDFS-13891.017.patch
          56 kB
          Íñigo Goiri
        23. HDFS-14117-HDFS-13891.018.patch
          55 kB
          Íñigo Goiri
        24. HDFS-14117-HDFS-13891.019.patch
          57 kB
          Íñigo Goiri
        25. HDFS-14117-HDFS-13891.020.patch
          58 kB
          Íñigo Goiri

        Issue Links

          Activity

            People

              ramkumar Ramkumar Ramalingam
              ramkumar Ramkumar Ramalingam
              Votes:
              0 Vote for this issue
              Watchers:
              15 Start watching this issue

              Dates

                Created:
                Updated: