Documentation

mc version

Description

The mc version commands enable, disable, and retrieve the versioning status for a MinIO bucket.

For more information about object versioning in MinIO, see Bucket Versioning.

mc version includes the following subcommands:

Subcommand

Description

enable

The mc version enable command enables versioning on the specified bucket.

info

The mc version info command returns the versioning status for the specified bucket.

suspend

The mc version suspend command disables versioning on the specified bucket.

Behavior

Object Locking Enables Bucket Versioning

While bucket versioning is disabled by default, configuring object locking on a bucket or an object in that bucket automatically enables versioning for the bucket. See mc retention for more information on configuring object locking.

Bucket Versioning with Existing Data

Enabling bucket versioning on a bucket with existing data immediately creates a null value version ID for each unversioned object.

Disabling bucket versioning on a bucket with existing versioned data does not remove any versioned objects. Applications can continue to access versioned data after disabling bucket versioning. Use mc rm --versions ALIAS/BUCKET/OBJECT to delete an object and all its versions.

S3 Compatibility

The mc commandline tool is built for compatibility with the AWS S3 API and is tested with MinIO and AWS S3 for expected functionality and behavior.

MinIO provides no guarantees for other S3-compatible services, as their S3 API implementation is unknown and therefore unsupported. While mc commands may work as documented, any such usage is at your own risk.