Object Storage - Getting started

Knowledge Base

Object Storage - Getting started


Icons/System/eye-open Created with Sketch. 5371 Views 07.04.2026 Cloud / Object Storage S3

Objective

This guide helps you manage your buckets and objects.

Learn how to create an Object Storage bucket and manage it.

If you are using legacy Swift Object Storage, then:

For new projects, we highly recommend using our S31-compatible Object Storage which benefits from our latest innovations and new features.

Requirements


OVHcloud Control Panel Access


Instructions

If you wish to use the OVHcloud Terraform provider, you can see the Terraform guide for Object Storage S3.

Preparation

To use the AWS CLI

To install the AWS CLI in your environment, see the official AWS documentation.

Check installation

aws --version

If you need more information about AWS CLI installation, read the AWS documentation.

Collect Credentials

  • Retrieve your user's Access key and Secret key. You can access this information in the Object Storage users tab in your OVHcloud Control Panel.
  • You will also need your endpoint_url. If you have already created your bucket, find this information in the My containers tab, then in the details of your bucket. If needed, see the Object Storage - Endpoints and Object Storage geoavailability guide.

Where to find the Endpoint URL of a bucket?

Click on the name of your bucket and view its details in the General information tab:

Bucket details

Configuration

Use the interactive configuration to generate the configuration files, or create them manually.

To use the interactive configuration, run the following command:

aws configure

or:

aws configure --profile <profile_name>

The configuration file format in the AWS client is as follows:

cat ~/.aws/credentials
[default]
aws_access_key_id = <access_key>
aws_secret_access_key = <secret_key>
cat ~/.aws/config
[default]
region = <region_in_lowercase>
endpoint_url = <endpoint_url>
services = ovh-rbx-archive

[profile <profile_name>]
region = rbx
output = json
services = ovh-rbx

[services ovh-rbx-archive]
s3 =
  endpoint_url = https://s3.rbx-archive.io.cloud.ovh.net/
  signature_version = s3v4

s3api =
  endpoint_url = https://s3.rbx-archive.io.cloud.ovh.net/

[services ovh-rbx]
s3 =
  endpoint_url = https://s3.rbx.io.cloud.ovh.net/
  signature_version = s3v4

s3api =
  endpoint_url = https://s3.rbx.io.cloud.ovh.net/

Here are the configuration values you can set:

VariableTypeValueDefinition
max_concurrent_requestsIntegerDefault: 10The maximum number of simultaneous requests.
max_queue_sizeIntegerDefault: 1000The maximum number of tasks in the task queue.
multipart_thresholdInteger
String
Default: 8MBThe size threshold that the CLI uses for multipart transfers of individual files.
multipart_chunksizeInteger
String
Default: 8MB
Minimum for uploads: 5MB
When using multipart transfers, this is the byte size that the CLI uses for multipart transfers of individual files.
max_bandwidthIntegerDefault: NoneThe maximum bandwidth that will be used to load and download data to and from your buckets.
verify_sslBooleanDefault: trueEnable / Disable SSL certificate verification

For a list of endpoints by region and storage class, see the Object Storage - Endpoints and Object Storage geoavailability guide.

Usage

If you have more than one profile, add --profile <profile_name> to the command line.

Using the OVHcloud Control Panel

To manage an Object Storage bucket, navigate to Object Storage in the left-hand menu.

Listing your buckets

Via AWS s3
aws s3 ls
Via AWS S3api
aws s3api list-buckets --query "Buckets[].Name" # Remove --query to display the full output.

Click on Object Storage in the navigation bar on the left and then on the My containers tab.

Enter the following command:

ovhcloud cloud storage-s3 list

Create a bucket

Via AWS s3
aws s3 mb s3://<bucket_name>
aws --profile <profile_name> s3 mb s3://<bucket_name>
Via AWS S3api
aws s3api create-bucket --bucket <bucket_name>
aws --profile <profile_name> s3api create-bucket --bucket <bucket_name>

Click Create Object Container:

Create your bucket part 1

You can enter the name of your bucket (optional) and then select your offer.

Select a deployment mode.

OVHcloud provides multiple deployment modes to meet different needs in terms of resilience, availability and performance. Each mode is optimized for specific use cases and offers varying levels of redundancy and fault tolerance.

Select a region.

Regions can vary depending on the chosen deployment mode.

You can then set the configuration parameters for your bucket.

Create your bucket part 2

If you have selected the 3AZ deployment mode, an additional option appears to configure offsite replication.

At this stage, you can decide whether or not to enable versioning.

Versioning allows you to keep multiple variants of an object in the same bucket. This feature helps preserve, retrieve, and restore every version of every object stored in your buckets, making it easier to recover from unintended user actions or application failures. By default, versioning is disabled on buckets; enable it explicitly if needed. For more information about versioning, see the Object Storage - Getting Started with Versioning guide.

You can also enable Object Lock to store your objects in WORM (Write Once, Read Many) mode and guarantee their immutability for a defined retention period.

Note: this option must be enabled when creating a bucket, it cannot be enabled later.

You must link a user to the bucket.

To do this, you can either:

  • Link an existing Object Storage user. To check the credentials, click on View credentials.
  • Or create a new Object Storage user.

You can now decide whether or not you wish to encrypt your data using SSE-OMK (server-side encryption with OVHcloud Managed Keys).

Once you have finished configuring your bucket, click Create.

Enter the following command, replacing <region> with your region code (e.g. GRA, BHS) and <bucket_name> with the desired name:

ovhcloud cloud storage-s3 create <region> --name <bucket_name>

To create a bucket with versioning and encryption enabled:

ovhcloud cloud storage-s3 create <region> --name <bucket_name> --versioning-status enabled --encryption-sse-algorithm AES256

To create a bucket with Object Lock enabled:

ovhcloud cloud storage-s3 create <region> --name <bucket_name> --object-lock-status enabled --object-lock-rule-mode compliance --object-lock-rule-period P30D

The --object-lock-status enabled option must be set at bucket creation time; it cannot be enabled later.

Uploading your files as objects in your bucket

When uploading objects, select a storage class to control availability, redundancy, and cost. To help you choose the right storage class for your needs, see the Choosing the right storage class for your needs guide.

To upload an object:

Via AWS s3
aws s3 cp /data/<object_name> s3://<bucket_name>

By default, objects are named after files, but they can be renamed.

aws s3 cp /data/<object_name> s3://<bucket_name>/other-filename

The aws s3 cp command will use STANDARD as default storage class for uploading objects. To store objects in the High Performance tier, use the aws s3api put-object command instead, as aws s3 cp does not support the EXPRESS_ONEZONE storage class which is used to map the High Performance storage tier. To learn more about the storage class mapping between OVHcloud storage tiers and AWS storage classes, you can check our documentation here.

Via AWS s3api
# upload an object to High Performance tier
aws s3api put-object --bucket <bucket_name> --key <object_name> --body /data/<object_name> --storage-class EXPRESS_ONEZONE

# explicitly upload an object to Standard tier
aws s3api put-object --bucket <bucket_name> --key <object_name> --body /data/<object_name> --storage-class STANDARD

By default, objects are named after files, but can be renamed.

aws s3 cp /data/<object_name> s3://<bucket_name>/other-filename

Click on the name of your container, then click the Add objects button in the Objects tab.

A window will appear where you can add a prefix to your object's name (the object name is the same as the file name). Select the file you are about to upload and click the Import button.

Downloading an object from a bucket

Via AWS s3

Downloading an object from a bucket:

aws s3 cp s3://<bucket_name>/<object_name> .

Uploading an object from one bucket to another bucket:

aws s3 cp s3://<bucket_name>/<object_name> s3://<bucket_name_2>/<object_name>

Downloading or uploading an entire bucket to the host/bucket:

aws s3 cp s3://<bucket_name> . --recursive
aws s3 cp s3://<bucket_name> s3://<bucket_name_2> --recursive
Via AWS s3api

Downloading an object from a bucket:

aws s3api get-object --bucket <bucket_name> --key <object_name> <object_name>

Uploading an object from one bucket to another bucket:

aws s3api copy-object --bucket <bucket_name_2> --copy-source <bucket_name>/<object_name> --key <object_name>

Click on the download icon (down arrow in a blue base) on the object line.

Synchronising buckets

aws s3 sync . s3://<bucket_name> # Synchronising local directory to the S3 bucket
aws s3 sync s3://<bucket_name> . # Synchronising S3 bucket to the local directory
aws s3 sync s3://<bucket_name> s3://<bucket_name_2> # Synchronising an S3 bucket to another one

Deleting objects and buckets

A bucket can only be deleted if it is empty.

Via AWS s3

Deleting objects and buckets:

# Delete an object
aws s3 rm s3://<bucket_name>/<object_name>
# Removing all objects from a bucket
aws s3 rm s3://<bucket_name> --recursive
# Delete a bucket. To delete a bucket, it must be empty.
aws s3 rb s3://<bucket_name>
# If the bucket is not deleted, you can use the same command with the --force option.
# This command deletes all objects from the bucket, then deletes the bucket.
aws s3 rb s3://<bucket_name> --force

Deleting objects and buckets with versioning enabled:

If versioning is enabled, a standard delete operation on your objects will not permanently remove them.

In order to permanently delete an object, you must specify a version id:

aws s3api delete-object --bucket <NAME> --key <KEY> --version-id <VERSION_ID>

To list all objects and their version IDs, use the following command:

aws s3api list-object-versions --bucket <NAME>

With the above delete-object command, iterate over all your object versions. You can also use the following one-liner to empty your bucket:

aws s3api delete-objects --bucket <NAME> --delete "$(aws s3api list-object-versions --bucket <NAME> --query='{Objects: Versions[].{Key:Key,VersionId:VersionId}}')"
Via AWS s3api

Deleting objects and buckets

# Delete an object
aws s3api delete-object --bucket <bucket_name> --key <object_name>
# Removing all objects from a bucket
aws s3api delete-objects --bucket <bucket_name> --delete "$(aws s3api list-objects-v2 --bucket <bucket_name> --query='{Objects: Contents[].{Key:Key}}')"
# Delete a bucket. To delete a bucket, it must be empty.
aws s3api delete-bucket --bucket <bucket_name>

Deleting objects and buckets with versioning enabled

If versioning is enabled, a standard delete operation on your objects will not permanently delete them.

To permanently delete an object, you need to specify a version identifier:

aws s3api delete-objects --bucket <bucket_name> --delete "$(aws s3api list-object-versions --bucket <bucket_name> --query='{Objects: Versions[].{Key:Key,VersionId:VersionId}}')"

If your bucket has Object Lock enabled, you will not be able to permanently delete your objects. See our documentation to learn more about Object Lock. If you use Object Lock in GOVERNANCE mode and have the permission to bypass GOVERNANCE mode, you will have to add the --bypass-governance-retention option to your delete commands.

Deleting a bucket

In the list of Object Storage containers, click the ... button on the container line, then click Delete.

Enter TERMINATE to confirm your choice and click Confirm.

Deleting objects

Go to the bucket and open the Objects tab.

Click the delete icon (trash can) on the object line, type PERMANENTLY DELETEto confirm permanent deletion, then click Delete.

Deleting objects

# Delete an object
ovhcloud cloud storage-s3 object delete <bucket_name> <object_name>

# Delete all objects in a bucket
ovhcloud cloud storage-s3 bulk-delete <bucket_name> --all

# Delete objects matching a prefix
ovhcloud cloud storage-s3 bulk-delete <bucket_name> --prefix <prefix>

# Delete specific objects
ovhcloud cloud storage-s3 bulk-delete <bucket_name> --objects "file1.txt,file2.txt"

Deleting a bucket

The bucket must be empty before deletion.

ovhcloud cloud storage-s3 delete <bucket_name>

Deleting objects with versioning enabled

If versioning is enabled, specify the version ID to permanently delete an object:

ovhcloud cloud storage-s3 object version delete <bucket_name> <object_name> <version_id>

To delete all versions of an object, combine the version list and deletion:

ovhcloud cloud storage-s3 bulk-delete <bucket_name> --objects "myfile.txt:<version_id_1>,myfile.txt:<version_id_2>"

Manage tags

Setting tags on a bucket:

aws s3api put-bucket-tagging --bucket <bucket_name> --tagging 'TagSet=[{Key=myKey,Value=myKeyValue}]'
aws s3api get-bucket-tagging --bucket <bucket_name>
{
  "TagSet": [
    {
    "Value": "myKeyValue",
    "Key": "myKey"
    }
  ]
}

Deleting tags on a bucket:

aws s3api delete-bucket-tagging --bucket <bucket_name>

Setting tags on an object:

aws s3api put-object-tagging --bucket <bucket_name> --key <object_name> --tagging 'TagSet=[{Key=myKey,Value=myKeyValue}]'
aws s3api get-bucket-tagging --bucket <bucket_name>
{
  "TagSet": [
    {
    "Value": "myKeyValue",
    "Key": "myKey"
    }
  ]
}

Deleting tags on an object:

aws s3api delete-object-tagging --bucket <bucket_name> --key <object_name>

The OVHcloud CLI lets you set tags on a bucket at creation time or when editing it via the --tag key=value option (repeatable for multiple tags). Individual tag management (reading, deleting) is not available via the CLI.

Setting tags when creating a bucket

ovhcloud cloud storage-s3 create <region> --name <bucket_name> --tag myKey=myKeyValue --tag otherKey=otherValue

Updating tags on an existing bucket

ovhcloud cloud storage-s3 edit <bucket_name> --tag myKey=myKeyValue

Go further

If you need training or technical assistance to implement our solutions, contact your sales representative or click on this link to get a quote and ask our Professional Services experts for assisting you on your specific use case of your project.

Join our community of users.

1: S3 is a trademark of Amazon Technologies, Inc. OVHcloud’s service is not sponsored by, endorsed by, or otherwise affiliated with Amazon Technologies, Inc.

Related articles