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
 General SQL Server Forums
 New to SQL Server Administration
 Tail Log backup

Author  Topic 

InfraDBA
Starting Member

38 Posts

Posted - 2011-06-05 : 12:46:49
I created a new database in my test instance.Then I restore the same database into the same instance.First time it went successfully.Then immediately I fired another restore the next second.I got the following message.(1)I want to know even though I haven't done a single transaction how come the question of tail log comes.(2)If I backup the log using norecovery then the restore happens fine.Please elaborate.I will be very thankful.

Msg 3159, Level 16, State 1, Line 1
The tail of the log for the database "TEST" 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.

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2011-06-05 : 14:32:04
It's just warning you that the DB is in full recovery and hence (since full recovery means you're worried about data loss) restoring may lose transactions. If you don't care either switch the DB to simple recovery or do the restore WITH REPLACE.

--
Gail Shaw
SQL Server MVP
Go to Top of Page

InfraDBA
Starting Member

38 Posts

Posted - 2011-06-05 : 15:54:27
Thank you..
Go to Top of Page

AlexGreen
Starting Member

8 Posts

Posted - 2011-06-20 : 10:13:50
You can check this link for further details about Tail-Log Backups http://msdn.microsoft.com/en-us/library/ms179314.aspx.
To avoid this message and you don't need a complex restore solution, try this free tool unspammed.

Good Luck.
Go to Top of Page
   

- Advertisement -