[
https://issues.apache.org/jira/browse/HDFS-8040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14391411#comment-14391411
]
Charles Lamb commented on HDFS-8040:
------------------------------------
Hi [[email protected]],
I tried reproducing this:
{code}
[cwl@localhost hadoop]$ hdfs crypto -listZones
/ez mykey
[cwl@localhost hadoop]$ hdfs dfs -ls /
Found 1 items
drwxr-xr-x - cwl supergroup 0 2015-04-01 15:41 /ez
[cwl@localhost hadoop]$ hdfs dfs -ls /ez
Found 1 items
-rw-r--r-- 3 cwl supergroup 158 2015-04-01 15:41 /ez/hosts
[cwl@localhost hadoop]$ hdfs dfs -D "fs.trash.interval=60" -rm -r /ez
15/04/01 16:41:15 INFO fs.TrashPolicyDefault: Namenode trash configuration:
Deletion interval = 60 minutes, Emptier interval = 0 minutes.
rm: Failed to move to trash: hdfs://localhost/ez: /ez can't be moved from an
encryption zone.
[cwl@localhost hadoop]$ hdfs dfs -ls -R /
drwxr-xr-x - cwl supergroup 0 2015-04-01 15:41 /ez
-rw-r--r-- 3 cwl supergroup 158 2015-04-01 15:41 /ez/hosts
drwx------ - cwl supergroup 0 2015-04-01 16:41 /user
drwx------ - cwl supergroup 0 2015-04-01 16:41 /user/cwl
drwx------ - cwl supergroup 0 2015-04-01 16:41 /user/cwl/.Trash
drwx------ - cwl supergroup 0 2015-04-01 16:41
/user/cwl/.Trash/Current
[cwl@localhost hadoop]$ hdfs dfs -ls -R /user/cwl/.Trash
drwx------ - cwl supergroup 0 2015-04-01 16:41
/user/cwl/.Trash/Current
[cwl@localhost hadoop]$ hdfs dfs -ls -R /user/cwl/.Trash/Current
{code}
Do you see any difference between what you did and what I did?
> Able to move encryption zone to Trash
> -------------------------------------
>
> Key: HDFS-8040
> URL: https://issues.apache.org/jira/browse/HDFS-8040
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: security
> Affects Versions: fs-encryption (HADOOP-10150 and HDFS-6134)
> Reporter: sumana sathish
>
> Users can remove encryption directory using the FsShell remove commands
> without -skipTrash option.
> {code}
> /usr/hdp/current/hadoop-hdfs-client/bin/hdfs dfs -D "fs.trash.interval=60"
> -rm -r /user/hrt_qa/encryptionZone_1
> 2015-04-01
> 19:19:46,510|beaver.machine|INFO|654|140309507495680|MainThread|15/04/01
> 19:19:46 INFO fs.TrashPolicyDefault: Namenode trash configuration: Deletion
> interval = 360 minutes, Emptier interval = 0 minutes.
> 2015-04-01
> 19:19:46,534|beaver.machine|INFO|654|140309507495680|MainThread|Moved:
> 'hdfs://sumana-dal-secure-4.novalocal:8020/user/hrt_qa/encryptionZone_1' to
> trash at: hdfs://sumana-dal-secure-4.novalocal:8020/user/hrt_qa/.Trash/Current
> 2015-04-01
> 19:19:46,863|test_TDE_trash|INFO|654|140309507495680|MainThread|Checking if
> the encryption zone is in Trash or not
> 2015-04-01
> 19:19:46,864|beaver.machine|INFO|654|140309507495680|MainThread|RUNNING:
> /usr/hdp/current/hadoop-client/bin/hadoop dfs -ls -R
> /user/hrt_qa/.Trash/Current
> 2015-04-01
> 19:19:46,892|beaver.machine|INFO|654|140309507495680|MainThread|DEPRECATED:
> Use of this script to execute hdfs command is deprecated.
> 2015-04-01
> 19:19:46,893|beaver.machine|INFO|654|140309507495680|MainThread|Instead use
> the hdfs command for it.
> 2015-04-01 19:19:46,893|beaver.machine|INFO|654|140309507495680|MainThread|
> 2015-04-01
> 19:19:50,289|beaver.machine|INFO|654|140309507495680|MainThread|drwx------
> - hrt_qa hrt_qa 0 2015-04-01 19:19 /user/hrt_qa/.Trash/Current/user
> 2015-04-01
> 19:19:50,292|beaver.machine|INFO|654|140309507495680|MainThread|drwx------
> - hrt_qa hrt_qa 0 2015-04-01 19:19
> /user/hrt_qa/.Trash/Current/user/hrt_qa
> 2015-04-01
> 19:19:50,296|beaver.machine|INFO|654|140309507495680|MainThread|drwxr-xr-x
> - hrt_qa hrt_qa 0 2015-04-01 19:19
> /user/hrt_qa/.Trash/Current/user/hrt_qa/encryptionZone_1
> 2015-04-01
> 19:19:50,326|beaver.machine|INFO|654|140309507495680|MainThread|-rw-r--r--
> 3 hrt_qa hrt_qa 3273 2015-04-01 19:19
> /user/hrt_qa/.Trash/Current/user/hrt_qa/encryptionZone_1/file_to_get.txt
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)