All Products
Search
Document Center

Object Storage Service:rb

Last Updated:Jul 31, 2024

You can run the rb command to delete a bucket.

Usage notes

To delete a bucket, you must have the oss:DeleteBucket permission.

Command syntax

ossutil rb oss://bucket [flags]

Parameter

Description

-f, --force

Specifies that the objects in the bucket are forcibly deleted.

Note

For more information, see Command-line options.

Examples

  • Delete an empty bucket named examplebucket:

    ossutil rb oss://examplebucket
  • Use the --force parameter to delete a non-empty bucket named examplebucket:

    ossutil rb oss://examplebucket --force