Aws-cli: aws s3 rb --force fails if versioning is enabled

Created on 21 Nov 2014  路  9Comments  路  Source: aws/aws-cli

aws s3 rb s3://bucket --force does not delete files permanently, but places delete markers instead.

It then fails with the following message:

remove_bucket failed: s3://bucket/ A client error (BucketNotEmpty) occurred when calling the DeleteBucket operation: The bucket you tried to delete is not empty. You must delete all versions in the bucket.

There is currently no way to delete the versions as well using aws s3 commands.

feature-request s3 s3versions

Most helpful comment

Based on community feedback, we have decided to return feature requests to GitHub issues.

All 9 comments

This will only happen if you've enabled versioning for your S3 bucket. You can do this using the low level s3api commands, but you are correct in that it is not possible to do this with the high level aws s3 commands. I think this would be a great feature request.

+1

+1

any updates on this?

any update on this ?

http://docs.aws.amazon.com/AmazonS3/latest/dev/delete-or-empty-bucket.html#delete-bucket-awssdks the java program is not working( it deletes only the main folders and when we click the show button the versioned ones are still there ) if versioning is enabled on a bucket.

I'm running into this.

Good Morning!

We're closing this issue here on GitHub, as part of our migration to UserVoice for feature requests involving the AWS CLI.

This will let us get the most important features to you, by making it easier to search for and show support for the features you care the most about, without diluting the conversation with bug reports.

As a quick UserVoice primer (if not already familiar): after an idea is posted, people can vote on the ideas, and the product team will be responding directly to the most popular suggestions.

We鈥檝e imported existing feature requests from GitHub - Search for this issue there!

And don't worry, this issue will still exist on GitHub for posterity's sake. As it鈥檚 a text-only import of the original post into UserVoice, we鈥檒l still be keeping in mind the comments and discussion that already exist here on the GitHub issue.

GitHub will remain the channel for reporting bugs.

Once again, this issue can now be found by searching for the title on: https://aws.uservoice.com/forums/598381-aws-command-line-interface

-The AWS SDKs & Tools Team

Based on community feedback, we have decided to return feature requests to GitHub issues.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rahul003 picture rahul003  路  3Comments

schams-net picture schams-net  路  3Comments

ypant picture ypant  路  3Comments

alexejk picture alexejk  路  3Comments

brettswift picture brettswift  路  3Comments