Blog Post

Restore fails with tail of log error

,

For sql server 2005 and above, When you take a full backup of the FULL recovered database and try to restore earlier backup it may fail with following error

Msg 3159, Level 16, State 1, Line 1

The tail of the log for the database “restoretest” has not been backed up. Use BACKUP LOG WITH NORECOVERY to backup the log if it contains work you do not want to lose. Use the WITH REPLACE or WITH STOPAT clause of the RESTORE statement to just overwrite the contents of the log.

Msg 3013, Level 16, State 1, Line 1

RESTORE DATABASE is terminating abnormally.

Error itself explains that the database is backuped up but not tail log backedup, due to which you cannot restore on that database.

There are two ways you can resotre on it

Create a log backup for that database and then restore with old backup.

Make that database into “Simple” recovery model so that the transaction log chain will be break and sql server will allow you to restore.

Rate

You rated this post out of 5. Change rating

Share

Share

Rate

You rated this post out of 5. Change rating