restore to point-in-time in EM

  • Hi all,

    Applying logs from Enetrprise Manager is straightforward because you have Backup Set Date.

    But if I need to automate it from QA, and the log backups don't have dates in their names, I need to do this manually one by one.

    I was thinking of writing a batch file to loop through log files in the backup_log folder, and query msbd.backupset table for backup_start_date, backup_finish_date values to compare to STOPAT parameter.

    But before I do that wanted to make sure there's not an easier way.

    Thanks for your help

  • Have you considered stacking all of your hourly log dumps onto a single file.

    The process that I use is to stack all of the log dumps onto a single file with a "fixed" file name (DatabaseName.BAK).   When the full database dump is taken this file name would be archived (using Grandfather / Father / Son -- Delete file "DatabaseName.BK2", rename "DatabaseName.BK1" to "DatabaseName.BK2", rename "DatabaseName.BAK" to "DatabaseName.BK1").

    You can then use the "RESTORE HEADERONLY" command to retrieve all the backup header information for all log dumps against the single file name.

    In this way you do not need to worry about obtaining physical file names.

       Rick

  • Rick, this is interesting. Do you mean your job backs up logs to one .bak file rather than .multiple .trn files? But how does it not overwrite it everytime, if the file has the same name?

    I guess I am asking what is the exact process of rolling all files into one.

     

    Thanks again

     

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply