Docs Ordnary Web Services Ordnary R2
On demand migration
Moving a bucket from Amazon S3 or Google Cloud Storage without downtime: objects are copied the first time they are requested.
On demand migration links a bucket to an existing bucket at another provider. When an object is requested from R2 and is not there yet, it is fetched from the source, stored in R2 and served. Over time the data you actually use moves over, with no bulk copy and no downtime.
Set it up
- 1
Create a read-only key at the source
A key that can list and read the source bucket. It never needs write access.
- 2
Enable migration on the R2 bucket
Under Settings, On demand migration: choose the provider, the region for Amazon S3, the source bucket and the key.
- 3
Point your application at R2
Switch the endpoint and key in your application. Reads of objects that are still at the source are served from there and copied on the way.
- 4
Copy the rest
Objects nobody requests stay at the source. Copy them with
aws s3 syncfrom the source to R2 when you are ready, then disable migration.
Source providerAmazon S3 | Google Cloud StorageRequired- Where the data is now.
Source regiontext- For Amazon S3, the bucket's region.
Source buckettextRequired- The bucket to migrate from.
Access key ID and secretcredentialsRequired- A read-only key for the source. Stored encrypted; shown nowhere afterwards.