Showing posts with label mode. Show all posts
Showing posts with label mode. Show all posts

Sunday, March 25, 2012

Accessing database in STANDBY mode while log shipping

Hi,

I am testing with Log shipping, I have it setup and it is working just fine. The secondary database was restored with Standby mode and is readonly. I have no problem accessing and querying data from the secondary database but I noticed if changes are made to the primary and I am accessing the database when the restore step to the secondary runs it fails with the following error:

Message
2006-07-31 09:40:54.33 *** Error: Could not apply log backup file 'C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Backup\LogShip\CI_REPLICATION_TEST_20060731131501.trn' to secondary database 'CI_REPLICATION_TEST'.(Microsoft.SqlServer.Management.LogShipping) ***
2006-07-31 09:40:54.33 *** Error: Exclusive access could not be obtained because the database is in use.
RESTORE LOG is terminating abnormally.(.Net SqlClient Data Provider) ***

This appears to be because you can not restore to a database that is in use? How do you get around this? Is it possible? How do I query data from the secondary db without worrying about causing log shipping to fail? Do I not worry about it because at somepoint when Exclusive access is obtainable all the logs will be rolled forward, but this could create a wide gap in sychronization between the primary and secondary db's, say if someone or something does not properly log off. I guess I could disconnect all users prior to applying tlogs but that kind of defeats the purpse of having it in read only mode so that data can be accessed? Couldn't really depend on it as a stable source of data for running data extracts? I suppose it could all just come down to timing everything in the appropriate sequence? Anyway.....

To sum up:

Is there anyway to access the standby server without causing the restore process to fail?

Both the Primary and Secondary are SQL 2K5.

Thanks!

Quick answer? No.

To load the t-logs, SQL Server needs exclusive access to the DB. So:

a) you allow read only access to continue, which can potentially block the t-log load

b) allow the t-log load, knowing that users will not be able to access the DB while the t-log is loading

c) kill the connections to the DB when the t-log is about to load, effectively creating b), but making unhappy end users

d) use another reporting solution

Log shipping has always been meant for creating a standby. While you can use it for read only access, it is not the best use of log shipping, and never has been. I have never ever recommended this configuration. YOu are better off setting up another way to do reporting and leave log shipping alone.

This is just the way the SQL engine works.

|||

Thanks!

Your basicly confirming, I guess, what I already knew. Just wanted to make sure I understood correctly.

Friday, February 24, 2012

Access Project 2002 compatibility with SQL Server Express

Hi,

When using an Access Project 2002 connected with SQL Server Express in OLE DB it's impossible to work in creation mode. A message explains that this Access version is not compatible with this SQL version.

Is there a service pack ?

Unfortunately, no. By now Access Project cannot be used in design mode of SQL Express. Do note that the next verson of ms-access will fix this.

Saturday, February 11, 2012

access denied using a trusted connection over a VPN

Hi - when i try to run a .NET app over my VPN using ADO.NET, a trusted conne
ction with SQL in mixed mode, i get 'access denied'. when i run the same app
from my local network thru the VPN, no problem..i'm using the same login an
d password for all computer
s(SQL Server is on another computer in the VPN network, which works fine w/t
rusted connection from the VPN server) How can i get access thru my VPN? Tha
nksAfter you have VPN'd in to your network. Test the following commands:
net use \\ServerName\IPC$
ISQL -Stcp:ServerName -E
Thanks,
Kevin McDonnell
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.|||I have the exact same problems. No problems when I'm connected to the
network.
When I'm at home using my vpn-client i'm not able to use trusted
connection.
I'm able to use net use \\myserver\ipc$ without any problems.
I have about 50 clients running Windows 2000 Pro SP4 and about 10 of
them are using VPN and 3 of them have the same problem as I.
I think that these errors started to occur sometime in july.
Might this be some Windowsupdate question..?
I use automatic download and install.
Thanks in advance.
lunatiic
---
Posted via http://www.mcse.ms
---
View this thread: http://www.mcse.ms/message743307.html