Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 Restore log problems

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-01-28 : 08:42:41
adam writes "I have trouble restoring the logs.
I had full backup and last differential backup restored, then I have tried restoring the last log number 69 since the last differential backup and I've got an error:
Server: Msg 4305, Level 16, State 1, Line 18
The log in this backup set begins at LSN 12188000000002000001,
which is too late to apply to the database. An earlier log backup that includes LSN 12169000000019200001 can be restored.
Server: Msg 3013, Level 16, State 1, Line 18
RESTORE LOG is terminating abnormally.

I tried to restore the earlier log backup num 68 and had a msg:
Server: Msg 4326, Level 16, State 1, Line 18
The log in this backup set terminates at LSN 12168000000037100001,
which is too early to apply to the database. A more recent log backup that includes LSN 12169000000019200001 can be restored.
Server: Msg 3013, Level 16, State 1, Line 18
RESTORE LOG is terminating abnormally.

Do you know what is wrong?"

efelito
Constraint Violating Yak Guru

478 Posts

Posted - 2002-01-28 : 11:31:55
Sounds like you're not applying the logs in the correct order. You have to apply all logs in order starting with the first log backup to occur after the differential backup. If you have the following backup schedule.

FullBackup.BAK - 12:00 AM
TranBackup.LOG - 1:00 AM
TranBackup.LOG - 2:00 AM
TranBackup.LOG - 3:00 AM
TranBackup.LOG - 4:00 AM
TranBackup.LOG - 5:00 AM
TranBackup.LOG - 6:00 AM
TranBackup.LOG - 7:00 AM
TranBackup.LOG - 8:00 AM
TranBackup.LOG - 9:00 AM
TranBackup.LOG - 10:00 AM
TranBackup.LOG - 11:00 AM
DiffBackup.BAK - 12:00 PM
TranBackup.LOG - 1:00 PM
TranBackup.LOG - 2:00 PM
TranBackup.LOG - 3:00 PM
TranBackup.LOG - 4:00 PM

If you wanted to restore to 3:00 PM, you would need to restore the backups in this order.

FullBackup.BAK - 12:00 AM
DiffBackup.BAK - 12:00 PM
TranBackup.LOG - 1:00 PM
TranBackup.LOG - 2:00 PM
TranBackup.LOG - 3:00 PM

HTH

Jeff Banschbach
Consultant, MCDBA
Go to Top of Page
   

- Advertisement -