This section describes the general format of backup and archive paths for AWS S3 and S3-compatible object storage, as well as the method for obtaining related information.
AWS S3
General format
The general format of an S3 backup or archive path is as follows:
s3://[bucket_name]/[path]?host=s3.[region].amazonaws.com&access_id=[AWS_Access_Key_ID]&access_key=[AWS_Secret_Access_Key]&s3_region=[region]
In the above path, s3://, /, ?host=, s3., .amazonaws.com, &access_id=, &access_key=, and &s3_region= are fixed components and do not need to be replaced. The following components need to be replaced:
[bucket_name]: the name of the AWS S3 bucket.[path]: the user-defined backup prefix under the bucket.[AWS_Access_Key_ID]: the AWS Access Key ID.[AWS_Secret_Access_Key]: the AWS Secret Access Key.[region]: the region where the AWS S3 bucket is located.
Obtain the required information
AWS Access Key ID, AWS Secret Access Key, and region
As an example, consider using AWS CLI. The information configured by the aws configure command corresponds to the AWS Access Key ID, AWS Secret Access Key, and region in the backup or archive path.
When you run the aws configure command, you are prompted to enter AWS Access Key ID, AWS Secret Access Key, and Default region name. These three parameters correspond to [AWS_Access_Key_ID], [AWS_Secret_Access_Key], and [region], respectively.
For example, the following statement shows how to configure the AWS Access Key ID, AWS Secret Access Key, and region using the aws configure command:
$ aws configure
AWS Access Key ID [None]: my_fake_access_id
AWS Secret Access Key [None]: my_fake_access_key
Default region name [None]: cn-north-1
Default output format [None]:
Bucket name
You can use the aws s3 ls command to list all buckets that you own.
Here is an example:
$ aws s3 ls
2025-07-07 17:08:50 mybucket1
2025-07-08 14:55:44 mybucket2
From the example, you can see that you own the mybucket1 and mybucket2 buckets. You can choose the name of the bucket that you want to use as the backup destination as [bucket_name] based on your needs.
Backup prefix under the bucket
The backup prefix [path] is user-defined. Ensure that no other objects exist under this prefix, provided that it complies with the prefix naming rules.
You can use the aws s3 ls command to list all objects and prefixes in a specified bucket.
Here is an example:
$ aws s3 ls s3://mybucket
PRE my_prefix/
2025-07-07 17:06:27 88 mydoc.txt
From the example, you can see that the mybucket bucket contains a root-level object named mydoc.txt and a prefix named my_prefix/. You can customize the backup prefix [path] to any prefix other than my_prefix/, such as my_prefix/backup/data.
Combine into a complete backup or archive path
Based on the method described above, the path-related information obtained in the text is as follows:
[bucket_name]: mybucket[path]: my_prefix/backup/data[AWS_Access_Key_ID]: my_fake_access_id[AWS_Secret_Access_Key]: my_fake_access_key[region]: cn-north-1
The final combined backup or archive path is as follows:
s3://mybucket/my_prefix/backup/data?host=s3.cn-north-1.amazonaws.com.cn&access_id=my_fake_access_id&access_key=my_fake_access_key&s3_region=cn-north-1
Object storage compatible with the S3 protocol, such as MinIO
For object storage compatible with the S3 protocol, such as MinIO, the general format of the backup or archive path is as follows:
s3://[bucket_name]/[path]?host=[endpoint]&access_id=[Access_Key_ID]&access_key=[Secret_Access_Key]
Where:
[bucket_name]: the name of the bucket in the third-party object storage service. For example: mybucket. The parameter has the same meaning as in AWS S3.[path]: the user-defined backup prefix in the bucket of the third-party object storage service. For example: my_prefix/backup/data. The way to obtain this parameter is similar to that in AWS S3.[endpoint]: the endpoint of the third-party object storage service.In AWS CLI, the endpoint is the same as the value specified by
[endpoint]. For example, in a locally deployed MinIO service, the endpoint is in the format of[ip]:[port], such as http://127.0.0.1:9000. For other third-party object storage services, please consult the corresponding service provider.Here is an example of accessing the endpoint of MinIO in AWS CLI:
$ aws s3 ls --endpoint http://127.0.0.1:9000 2025-07-07 17:08:50 mybucket1 2025-07-08 14:55:44 mybucket2[Access_Key_ID]: the Access Key ID of the third-party object storage service. For example: my_fake_access_id. The parameter has the same meaning as in AWS S3.[Secret_Access_Key]: the Access Key of the third-party object storage service. For example: my_fake_access_key. The parameter has the same meaning as in AWS S3.
For example, the final integrated backup or archive path for MinIO is as follows:
s3://mybucket/my_prefix/backup/data?host=http://127.0.0.1:9000&access_id=my_fake_access_id&access_key=my_fake_access_key