This lab will take you through the process of enabling object versioning and configuring CRR (Cross Region Replication).
-
Go to the S3 console, select your S3 bucket (stg209-student-#), click on Properties tab
-
Click on Versioning, select Enable versioning, click Save
-
Go to your S3 bucket (stg209-student-#) and navigate to the folder "lab4/version1".
-
Click on Versions: Show to observe the current state of the files in this folder.
As you can see, there is only one version of each file. Feel free to open any txt file. It will read "This is version 1".
-
Navigate to the folder "lab4/version2".
-
Turn off versions view by selecting Versions: Hide.
-
Select the checkmark at the top left corner to select all the files.
-
Click Actions and choose Copy to copy all the files in this folder.
-
Navigate back to folder "lab4/version1" and choose Actions, then Paste to write the contents to the folder. Click Paste.
-
Click on Versions: Show. You now have multiple versions of the same file. Each version has a unique Version ID.
-
Open both versions of the same file. The "Latest" will read "This is version 2". The older file will read "This is version 1". If you delete the "Latest" version of a file, it will promote the older version to "Latest".
-
A target bucket has already been created for you. It will have "CRR" in the name e.g.stg209-crr-student-#. Versioning is required in both the source and destination buckets.
-
Enable "Versioning" on your destination (CRR) bucket. Follow the same instructions as above.
-
Go to the source bucket (without CRR in the name).
-
Click on the Management tab and choose Replication
-
Click on "+ Add Rule"
-
Select Entire bucket. Do not enable encryption. Click Next
-
Set Destination bucket. Buckets in this account. Find and choose your assigned CRR bucket (stg209-crr-student-#). Leave Options blank. Click Next
-
On step 3-Configure options, For IAM role Select Create new role. Name the rule "s3-crr-student#". Click Next
-
Review Source, Destination, Options and Click Save
-
Remember...CRR only replicates "new" PUTs and Objects. Test the replication by copying and pasting files into the source bucket. The objects will automatically be copied to your destination bucket.
-
If you do not see the files in the destination folder, wait a few seconds, then use your browsers reload button and check again.
Congratulations! You have completed the Lab 4.
This ends the lab portion of this session.
Please remember to fill out your session survey!