While creating an RDS snapshot, we found that the snapshot contained dirty data

  1. We are creating an RDS snapshot and then immediately writing some data to the RDS instance; we found that the snapshot contained the data that was just written.

    • Why would this data be recorded in a recently created snapshot?
  2. Similarly, when we create a snapshot and wait for some time (such as: 3 min), then write data to the RDS instance, we will get a clean snapshot.

    • Why do we need to wait some time?
    • Will this "wait time" change as the amount of data in the RDS instance increases, or if there are changes in the cluster architecture?
asked 10 months ago583 views
2 Answers

I am not sure what you mean here by clean and dirty snapshots. But I would disagree with the first answer here. An RDS snapshot is created immediately at the time of the request. It will produce a crash consistent copy of the database. So 'waiting three minutes' would write data that is not included in the snapshot. The first case, you must have written the data prior to requesting the snapshot.

answered 10 months ago
    1. I understand snapshots save the current state of RDS immediately. After sending a request to create a snapshot, all subsequent operations on RDS should not be recorded in the snapshot. Through our test, after sending the request to create a snapshot, some data will be inserted into the RDS instance immediately, and these insertion operations will be recorded in the snapshot, I don't think this is as expected.

    2. When you create a snapshot on the RDS service, the snapshot's state is 'Creating'. If you immediately operate (such as inserting some data) on the RDS that's currently being backed up and these operations get recorded in the snapshot, this would lead to what's known as a 'dirty snapshot', because these operations should not be recorded into the snapshot. Conversely, if such operations are not included, it's described as a 'clean' snapshot.


A snapshot isnt instant. Depending on the size of the RDS it can take several minutes. Depending on when the snapshot starts and finishes will dictate what data is included.

Perform the same tests while monitoring the Snapshot screen of RDS to know when the snaphost has completed.

profile picture
answered 10 months 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