Search code examples
amazon-web-servicesamazon-s3aws-sdk-go

Delete a weird object in s3 bucket


I somehow endedup creating a weird object name in aws s3 bucket which is something like: 

I tried deleting it from aws cli, aws-sdk-go and from the aws console as well. Nothing seems to work. Has anyone faced an issue like this and how did you counter it?

P.S: My bucket contains 24 giga bytes of data.

s3-bucket-image


Solution

  • Using aws-cli, I moved the objects I wanted to keep to another folder. After that, I ran:

    $ aws s3 rm s3://mybucket/public/0 --recursive  
    # where 0 is the directory containing the object I wanted to delete