https://github.com/emcecs/bucket-wipe
https://github.com/emcecs/bucket-wipe
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/emcecs/bucket-wipe
- Owner: EMCECS
- License: apache-2.0
- Created: 2019-01-23T00:32:08.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2023-07-25T14:19:11.000Z (almost 3 years ago)
- Last Synced: 2025-05-30T16:16:26.449Z (about 1 year ago)
- Language: Java
- Size: 332 KB
- Stars: 5
- Watchers: 13
- Forks: 2
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Bucket Wipe
The purpose of the bucket-wipe tool is to enumerate a bucket and delete its contents in parallel threads. At the end the bucket is optionally deleted. This tool is required because you cannot (for safety reasons) delete a non-empty bucket.
Current Version: 2.1.0
# Disclaimer about deleting data
WARNING: THIS TOOL PERMANENTLY DELETES ALL DATA IN A BUCKET, INCLUDING ALL VERSIONS!! Even if you have versioning enabled, the tool will destroy all data in the bucket and (by default) the bucket itself. If this is not what you want, use a different tool.
# Usage
Bucket Wipe is a Java application and can be run using the `java -jar` command followed by the location of the JAR file. Running without any other arguments will produce command-line help.
```
usage: java -jar bucket-wipe.jar [options]
-a,--access-key the S3 access key
--delete-mpus incomplete MPUs will prevent the bucket
from being deleted. use this option to
clean up all incomplete MPUs
-e,--endpoint the endpoint to connect to, including
protocol, host, and port
-h,--help displays this help text
-hier,--hierarchical Enumerate the bucket hierarchically. This
is recommended for ECS's
filesystem-enabled buckets.
--keep-bucket do not delete the bucket when done
-l,--key-list instead of listing bucket, delete objects
matched in source file key list
--no-smart-client disables the ECS smart-client. use this
option with an external load balancer
-p,--prefix deletes only objects under the specified
prefix
-s,--secret-key the secret key
--stacktrace displays full stack trace of errors
-t,--threads number of threads to use
--vhost enables DNS buckets and turns off load
balancer
```
Note that if you are using an endpoint that is a load balancer, you will want to use --no-smart-client to turn off the built-in software load balancer.
For more information, please see the [wiki](https://github.com/EMCECS/bucket-wipe/wiki)
# How to Build
You should only need to build this tool for development purposes.
1. Clone bucket-wipe tool from githib
```
$ git clone https://github.com/EMCECS/bucket-wipe.git
```
2. cd to the bucket-wipe directory
```
$ cd bucket-wipe
```
3. Build jar file
```
$ ./gradlew shadowJar
```
4. The build will be located in `/bucket_wipe/build/libs/bucket-wipe-1.10.jar`