Description
As a non-superuser, when you create and delete a snapshot but accidentally specify a non-existent directory to snapshot, you will see an extra/unnecessary permission denied error right after the "No such file or directory" error.
[schu@hdfs-snapshots-vanilla ~]$ hdfs dfs -deleteSnapshot /user/schuf/ snap1 deleteSnapshot: `/user/schuf/': No such file or directory deleteSnapshot: Permission denied [schu@hdfs-snapshots-vanilla ~]$ hdfs dfs -createSnapshot /user/schuf/ snap1 createSnapshot: `/user/schuf/': No such file or directory createSnapshot: Permission denied
As the HDFS superuser, instead of the "Permission denied" error you'll get an extra "Directory does not exist" error.
[root@hdfs-snapshots-vanilla ~]# hdfs dfs -deleteSnapshot /user/schuf/ snap1 deleteSnapshot: `/user/schuf/': No such file or directory deleteSnapshot: Directory does not exist: /user/schuf
Attachments
Issue Links
- is duplicated by
-
HDFS-5111 Remove duplicated error message for snapshot commands when processing invalid arguments
- Closed