File deletion with datasync if versioning is enabled.

0

What is happening if I'm syncing a File System with S3 versioning enabled, and I delete a file? I suppose that a delete marker is added, so the previous versions are kept. This mean that the client will have probably to do additional activities to clean up files deleted over a period of time if they want to keep their storage cost low.

correct? THanks.

1 Answer
0
Accepted Answer

Yes, that is my understanding. With versioning enabled, deletions in the file system will not remove the previously synced versions of the file store in S3 automatically. An object expiration lifecycle policy may be a helpful resource in reducing storage costs here.

If you have an object expiration lifecycle policy in your non-versioned bucket and you want to maintain the same permanent delete behavior when you enable versioning, you must add a noncurrent expiration policy. The noncurrent expiration lifecycle policy will manage the deletes of the noncurrent object versions in the version-enabled bucket. (A version-enabled bucket maintains one current and zero or more noncurrent object versions.) For more information, see How Do I Create a Lifecycle Policy for an S3 Bucket? in the Amazon Simple Storage Service Console User Guide

(https://docs.aws.amazon.com/AmazonS3/latest/dev/Versioning.html)

AWS
EXPERT
JDB
answered 4 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions