January 29, 2008 at 8:23 am
Hi, Pls can anyone help me, am setting up Database Mirroring between two server using Developer Edition.
I did a full backup of the Principal Database and restore it onto the Mirror with no recovery, then did a transaction log back up, but when I try to restore it, I get error message (System.Data.SqlClient.SqlError: The log in this backup set begins at LSN 46000000259700001, which is too recent to apply to the database. An earlier log backup that includes LSN 46000000259200001 can be restored. (Microsoft.SqlServer.Smo)).
That the transaction log is too recent, to choose an earlier one with a different LSN, see the full error message below.
I restored the full back with no recovery, will I have to restore the transaction log "with recovery"or "with no recovery"
===================================
Restore failed for Server 'ADESINA\JUMOKE'. (Microsoft.SqlServer.Smo)
------------------------------
------------------------------
Program Location:
at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)
at Microsoft.SqlServer.Management.SqlManagerUI.SqlRestoreDatabaseOptions.RunRestore()
===================================
System.Data.SqlClient.SqlError: The log in this backup set begins at LSN 46000000259700001, which is too recent to apply to the database. An earlier log backup that includes LSN 46000000259200001 can be restored. (Microsoft.SqlServer.Smo)
------------------------------
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.3042.00&LinkId=20476
------------------------------
Program Location:
at Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteNonQueryWithMessage(StringCollection queries, ServerMessageEventHandler dbccMessageHandler, Boolean errorsAsMessages)
at Microsoft.SqlServer.Management.Smo.BackupRestoreBase.ExecuteSql(Server server, StringCollection queries)
at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)
January 29, 2008 at 9:45 am
Did you restore your log file in order? If you miss any earlier log file, you will get the error message.
January 29, 2008 at 10:35 am
Hi, thanks for the reply, the database am using has a job that backs up the transaction log every day, so I guess there will be loads of log files.
What I did was take the full backup, restored it with "no recovery" then a transaction log backup after that and restored only that transaction log backup. Am doing it as a test not production, would I have to restore all the previous log backup ( there are many of them and from what date).
January 29, 2008 at 12:39 pm
You need to restore the full backup first. Then,
The very first log backup after the full backup.
The second log backup after the full backup.
...
January 29, 2008 at 12:44 pm
fosco (1/29/2008)
would I have to restore all the previous log backup ( there are many of them and from what date).
Yes. You have to restore the log backups, in order, starting with the first one after the full backup that you used.
If you're setting up database mirroring, all or your transaction log backups, including the last must be restored with no_recovery
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
February 5, 2008 at 9:29 pm
You can make use of these links to configure database mirroring in SQL Server 2005. If you have any queries pls, let us know. The below mentioned has all the screenshots attached and provides a step by step guidance.
http://sql-articles.com/index.php?page=articles/cng-dbmrr.htm
http://sql-articles.com/index.php?page=articles/dbmrr.htm
Hope this Helps
[font="Verdana"]- Deepak[/font]
February 6, 2008 at 2:47 am
Thanks
June 12, 2008 at 1:56 am
i am also getting the same error , while configuring log shipping , I did a full backup in PROD server and restored in COB and then took a log backup backup and while restoring it in COB server Error "which is too recent to apply to the database" (only one log backup is done )
June 12, 2008 at 2:07 am
Check that there's no automatic log backup job running and that the log hasn't been truncated between the full backup and the log backup you took.
The error 'too recent...' implies that there are log records missing.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
June 12, 2008 at 2:34 am
Also ensure that nobody has truncated the log file using Backup log with truncate_only or no_log command. Because the usage of the above commands will break the LSN and hence your log shipping might fail..
[font="Verdana"]- Deepak[/font]
June 12, 2008 at 9:15 am
no log trunation happeded , i repeated the steps what i have explained earlier , Log shipping worked successfully
(still wondering wat went wrong). Thanks for your valauble points
October 31, 2008 at 8:11 am
GilaMonster,
Thanks a lot for the tip. I was getting the same error and there was this job which was truncating the logs after the full backup
Thanks a lot
October 31, 2008 at 8:37 am
avi27 (10/31/2008)
GilaMonster,Thanks a lot for the tip. I was getting the same error and there was this job which was truncating the logs after the full backup
Thanks a lot
You should never be truncating your transaction log. See today's headline article.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 13 posts - 1 through 12 (of 12 total)
You must be logged in to reply to this topic. Login to reply