S3 objects replication in AWS – Legendshub Blog

In this blog we will discuss on “How to setup replication in the buckets residing the different AWS accounts ? “

We will take a scenario in which we have two accounts A and B. We want to replicate the objects from bucket Source in account A to bucket Destination in account B.

First of all open the account A and click on the source bucket. Click on the management and go the replication rules section. Create a new replication rule.

In replication rule chose the option accordingly. If you want to limit the rule to filter incase any subfolder or prefix define here. If complete bucket need to be synced select other option.

Select the the destination bucket accordingly if bucket is in same account or if bucket is present in other AWS account.

For replication one need to create the proper IAM role. If you are unaware of the permissions need choose option to create a new role. If reference is needed follow policy can be used.

“Version”: “2012-10-17”,
“Statement”: [
“Action”: [
“s3:Get“, “s3:ListBucket” ],

“Effect”: “Allow”,

“Resource”: [ “arn:aws:s3:::bucketname”,

“Action”: [
“Effect”: “Allow”,
“Resource”: “arn:aws:s3:::buketname/*”

Next part is important for destination bucket prospective. If you want to replicate all the existing objects or want to replicate only new objects. Generally after replication rule is configured it may take upto 48 hours to replicate but if one selects RTC it will ensure objects are replicated in 15 mins.

Note: Replication rules will only work if versioning is enabled on both source and destination bucket.

Once everything is configured save the replication rule.

Amrit Pal singh

Designing critical migration from legacy to cloud environments, extending devops approach into analytics, AI/ML to maximize the purpose of agile approach. We work to integrate compliance with risk, security and regulations, building seamless interfaces across multiple systems. I am fortunate to manage complex hierarchy of global portfolios, programs and projects and executive communication . Provide TCO analyses to low level architecture, design and implementation, readiness and building BCP/DR/HA, and around the clock monitoring & management using cloud tools relevant to our customer's situation and objectives.

  2 comments for “S3 objects replication in AWS – Legendshub Blog

Leave a Reply