Timing specific questions for database refresh

  • 0
  • 1
  • Question
  • Updated 3 years ago
  • Answered
I have two main questions when it comes to refreshing a database:

1) How often should a snapshot be performed prior to a refresh? Say we will do a database refresh at 12a. Are there recommendations for the frequency and time frame for snapshots prior to this time (8p, 10p, etc)? At what point is too many snapshots a bad idea?

2) Prior to refreshing a database, we run ALTER SYSTEM ARCHIVE LOG CURRENT on the source database. After this command is run:
   a) Can a VDB refresh be started immediately for refreshing to LATEST?
   b) Can a VDB refresh be started from LATEST and at the same time, new activity be written to the source database? For example:
         i) 11:50 - database activity is stopped
         ii) 11:51 - system archive logs are flushed via above command
         iii) After above is complete: start VDB refresh
         iv) Can new activity be written to source DB while above refresh is still ongoing? Or would that new activity conflict with the refresh?

Hope that is clear! Thank you!
Photo of Ross Bender

Ross Bender

  • 80 Points 75 badge 2x thumb

Posted 3 years ago

  • 0
  • 1
Photo of Imran

Imran

  • 240 Points 100 badge 2x thumb

1) Normally once a day snapsync is enough. If you have log sync enabled delphix will get archive logs and keep your snapshot up to date. Timing of snapshot should be dependent on your database as you may wana run it at time when your database is not too busy. Just like you do with normal backups.

2 Normally delphix gets archive log as soon as you perform "Alter system archive log current" (I am not aware of delphix internal mechanism but this is what I noticed on my systems). You can test this by performing log switch on source database and look at latest snapshot timeflow card. End timestamp value will change.

a) I would give it a little time just to make sure latest log switch make it to delphix.

b) For database refresh you don't have to stop activity on source database. You refresh your database from dSource not srouce database. They are independent of each other.

Thanks

Photo of Ross Bender

Ross Bender

  • 80 Points 75 badge 2x thumb
How would one know (programmatically) when the latest log switch makes it to Delphix? Or would waiting x number of seconds be appropriate?
Photo of Imran

Imran

  • 240 Points 100 badge 2x thumb

You can find latest log time using timeflowRanges

timeflow select db_name timeflowRanges

commit

Timestamp in End point section is what you need.