I've been working on some code to be able to reverse catalog a set of
backups into the msdb backup* tables, which was easy, but now I'm struggling
with the necessary code to create the restore commands for an arbitrary
point in time.
My question is what is the appropriate logic or psuedo code for walking a
tree backup resources to get to a point in time.
I believe the following to be appropriate logic, but would like
verification:
full backup id = (max (checkpointlsn) where finishtime<[point in time]) and
type = 1
differential backup id = (max(checkpointlsn) where backuplsn = full backup
checkpointlsn and type = 5 and finishtime<[point in time])
But I am still struggling with the T-log resources and how to put it all
together (like for example, if you simply cannot get to a given point in
time given a set of files, and only wanting to restore the necessary the
last t-log where the lsn hasn't changed in 10 backup files)
Help!?
Bump
<news@.news.com> wrote in message
news:%23l52asjXEHA.1656@.TK2MSFTNGP09.phx.gbl...
> I've been working on some code to be able to reverse catalog a set of
> backups into the msdb backup* tables, which was easy, but now I'm
struggling
> with the necessary code to create the restore commands for an arbitrary
> point in time.
> My question is what is the appropriate logic or psuedo code for walking a
> tree backup resources to get to a point in time.
> I believe the following to be appropriate logic, but would like
> verification:
> full backup id = (max (checkpointlsn) where finishtime<[point in time])
and
> type = 1
> differential backup id = (max(checkpointlsn) where backuplsn = full backup
> checkpointlsn and type = 5 and finishtime<[point in time])
> But I am still struggling with the T-log resources and how to put it all
> together (like for example, if you simply cannot get to a given point in
> time given a set of files, and only wanting to restore the necessary the
> last t-log where the lsn hasn't changed in 10 backup files)
> Help!?
>
>
>
>
>
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment