question

rohits avatar image
rohits asked

Tail log backup query in log shipping reversal

Hello, I am doing log shipping failover and failback configuration in SQL Server 2008 R2 environment. During the Failover, I am taking the tail log backup of primary database with query: -- Script to backup Log------- DECLARE @filepath VARCHAR(200) SET @filePath=N'\\ClusterName\SQL_Tail_Backup\DBNAME_Tail_Log.trn' BACKUP LOG [DBNAME] TO DISK = @filePath WITH NO_TRUNCATE, NOFORMAT, INIT, NAME = N'DBNAME-Tail Log Backup', SKIP, NOUNLOAD, NORECOVERY, STATS = 10 And script for Log restore is: -- Script to restore Log------- DECLARE @filepath VARCHAR(200) SET @filePath=N'\\ClusterName\SQL_Tail_Backup\DBNAME_Tail_Log.trn' RESTORE LOG [DBNAME] FROM DISK = @filepath WITH RECOVERY; GO But after making secondary database writable, my applications are not connecting to the database. While, trying backup and Restore from GUI works well. Please Help! Thanks in Advance. Rohit
sql-server-2008-r2log-shipping
2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Magnus Ahlkvist avatar image Magnus Ahlkvist commented ·
What does "my applications are not connection to the database" mean? Do you get error messages? What happens?
0 Likes 0 ·
rohits avatar image rohits commented ·
The error is: "A network related or instance-specific error occurred while eshtablishing a connection to SQL Server. The server was not found or was not accessible." I wanted to know if the parameter I am passing during the backup are okay??
0 Likes 0 ·

0 Answers

·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.