DEV Community

Cover image for AWS S3-Replication
Kannan
Kannan

Posted on

AWS S3-Replication

  • Amazon Simple Storage Service (S3) Replication is an elastic, fully managed, low cost feature that replicates objects between buckets.

  • To automatically replicate new objects as they are written to the bucket, use live replication, such as Cross-Region Replication (CRR). To replicate existing objects to a different bucket on demand, use S3 Batch Replication.

Step1. Now we create source S3 Bucket make sure to enable the versioning and upload one file.

Image description

Image description

Step2. Create a another Destination S3 bucket with versioning enabled.
Image description

Step3. Now on the source Bucket >management >Replication rules.
we need to create these replication rules on the source bucket.

Image description

  • Choose the destination bucket on the replication rules.alternative you can choose the different AWS account/S3 Bucket to replicate.

Image description

  • On the "IAM role" create new role for these job.

Image description

  • Once replication rule has been created need to confirm either you need to replicate existing objects or not.

Image description

Step4. At "Create Batch operation job" we are disabling the "Generate completion report" and create new IAM role.

Image description

Image description

  • The file which we uploaded on the source bucket is replicated on the Destination bucket using "Replication Rules".

Image description

Step5. If we upload new file/object on the source bucket it will automatically replicate on Destination bucket.

Image description

Image description

Image description

  • Similar we can use Cross-Region Replication (CRR).
  • To enable CRR, you add a replication configuration to your source bucket. The minimum configuration must provide the following:

The destination bucket or buckets where you want Amazon S3 to replicate objects

An AWS Identity and Access Management (IAM) role that Amazon S3 can assume to replicate objects on your behalf

Top comments (0)