hadoop-hdfs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ritesh Kumar Singh <riteshoneinamill...@gmail.com>
Subject Re: Delete a folder name containing *
Date Thu, 21 Aug 2014 05:40:20 GMT
just to be sure, try this one too:

hadoop fs -rmr /data/"folder\*"


On Thu, Aug 21, 2014 at 1:36 AM, praveenesh kumar <praveenesh@gmail.com>
wrote:

> Command used -
>
> 1. hadoop fs -rmr /data/folder\*
> 2. hadoop fs -rmr 'data/folder\*'
> 3. hadoop fs -rmr "/data/folder\*"
>
> None of them gave any output. Hadoop version - 1.0.2
>
>
> On Wed, Aug 20, 2014 at 7:26 PM, Ritesh Kumar Singh <
> riteshoneinamillion@gmail.com> wrote:
>
>> what's the exact command you are using(with escape and quotes)?
>> And what's the output after execution?
>>
>>
>> On Wed, Aug 20, 2014 at 9:33 PM, hadoop hive <hadoophive@gmail.com>
>> wrote:
>>
>>> Move it to some tmp directory and delete parent directory.
>>> On Aug 20, 2014 4:23 PM, "praveenesh kumar" <praveenesh@gmail.com>
>>> wrote:
>>>
>>>> Hi team
>>>>
>>>> I am in weird situation where I have  following HDFS sample folders
>>>>
>>>> /data/folder/
>>>> /data/folder*
>>>> /data/folder_day
>>>> /data/folder_day/monday
>>>> /data/folder/1
>>>> /data/folder/2
>>>>
>>>> I want to delete /data/folder* without deleting its sub_folders. If I
>>>> do hadoop fs -rmr /data/folder* it will delete everything which I want to
>>>> avoid. I tried with escape character \ but HDFS FS shell is not taking it.
>>>> Any hints/tricks ?
>>>>
>>>>
>>>> Regards
>>>> Praveenesh
>>>>
>>>
>>
>

Mime
View raw message