Ask Your Question
0

Remove all empty containers in one go [Swift]

asked 2016-03-09 05:52:38 -0500

Aun gravatar image

updated 2016-03-09 05:53:43 -0500

I looked around but couldn't find any solution. I run some tests on swift setup and it created more than 100 empty containers. Now I'm looking for a way to remove all the current containers in my swift setup in one go. Any command or any option from Horizon which let me do this? sure i can delete each container individually but that will take enough time. Any help will be appreciated. Thanks!

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
0

answered 2016-03-09 09:13:49 -0500

Bipin gravatar image

Hi

The following will work

for i in $(swift list); do swift delete $i; done
edit flag offensive delete link more
0

answered 2016-03-09 08:00:03 -0500

Aun gravatar image

updated 2016-03-09 08:01:48 -0500

I found an ugly way to do it, I installed Cyberduck, logged in my account in this application, selected and deleted all containers, but I'm still interested to know if there is any such swift command?

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2016-03-09 05:52:38 -0500

Seen: 119 times

Last updated: Mar 09 '16