Moving A SQL Server 2000 Database That Is In Standby Mode
Jul 20, 2005
SQL Users/DBAs,
I'm trying to move data files around for a database that is in standby
mode. I can detach/attach the database fine using
SP_DETACH_DB/SP_ATTACH_DB , but when I re-attach the database the log
sequence is broken and I can't restore any more logs. Does anyone
know if there is a way to move around data files and keep the database
in standby mode?
How can I get a SQL Server 2005 database out of Standby/Read-only mode? I just restored this DB sent from a customer and it is in Standby/Read-only mode. I need to add a user so that I can authenticate from my app for testing purpose.
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 FilesMicrosoft SQL ServerMSSQL.1MSSQLBackupLogShipCI_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?
We have the following scenario: Server A replicates Database A to Server B. Server C has Database A on it as well, but in standby mode. We are applying the transaction logs generated by Database A on Server A to the database on Server C leaving it in standby mode each time.
Let's say we had planned maintenance for Server Aand dumped the last set of transactions on Server A in standby mode to be applied to to Server C. What happens to the replica on Server B? When I start to use Server C, can I backup its transactions and apply them to Server A, and then have those transactions replicated to Server B? And then what do I do when the maintenance is complete so that I can swithc back to Server A and have the replication continue on as before the maintenance to Server B?
We are using MSSQL 2005 and Log Shipping. After making our secondary SQL server primary, how can we put the secondary SQL server back into standby mode?
one of my sql database went in suspect mode can any one advice why it has happened is it the problem with sql server . This has happend for the second time in 4 months .
I have a question about log shipping and assembly on the secondary server. I have configured log shipping to the secondary server and the secondary server in standby/read-only mode. I have test everything for reading from that database on the secondary server; and all ended with great seccess, except for assembly.
My assembly simply turn bytes into text or the other way using UTF-8 encoding, nothing serious, and I have checked that assembly on both server have the same thing every where. However, I continue getting the error:
Msg 10314, Level 16, State 11, Line 1 An error occurred in the Microsoft .NET Framework while trying to load assembly id 65574. The server may be running out of resources, or the assembly may not be trusted with PERMISSION_SET = EXTERNAL_ACCESS or UNSAFE. Run the query again, or check documentation to see how to solve the assembly trust issues. For more information about this error: System.IO.FileLoadException: Could not load file or assembly 'asp.clr, Version=2.5.0.1, Culture=neutral, PublicKeyToken=9ed52bcb68360e98' or one of its dependencies. Assembly in host store has a different signature than assembly in GAC. (Exception from HRESULT: 0x80131050) System.IO.FileLoadException: at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection) at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) at System.Reflection.Assembly.InternalLoad(String assemblyString, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection) at System.Reflection.Assembly.Load(String assemblyString)
I have tested this assembly on the secondary in a read-write database, and it works fine. I can see both assembly sharing the same same thing ...
Is there a limitation for read-only database on assembly using?
I am trying to move a database which I wrote in SQL Server 2005 to a SQL Server 2000 database. I'm not sure the best way to do this....... Can anyone enlighten me?.....
Hi, i was after some advice on moving a SQL Server 2000 database from one server to another.
Usually i would do this by backing up the database on the original server the copying it accross the LAN to the new server and restoring it there. This database is 10Gb in size and copying it accross the LAN will take some time and i would like to minimise downtime if possible. The database is at a customer site where i am not responsible for the network or Hardware.
I have detached my database from the server and copied the mdf and ldf files to the new PC do I need to do anything but attach it to the MSDE? What about logins, roles, etc... does all this remain the same or do I need to delete the old and reenter them?
I have used backup and restore method to upgrage 2000 databases to 2005 database. What do i need to do in order to for my application or users to use databse in 2005 and remove 2000
I've been reading a million and one posts on replication
My scenario is that i have a live SQL 2000 server. In a DR invokation, i'e i've lost my live sever, i want to be able to access the same data at the DR (SQL 2000) site and have it accessable to the users. DR server has a different name to the live box.
Replicate
Master CRMDatabase
Data changes all the time but can have hourly replication of transaction logs for this example. I've currently researched a sp called update logons but this has to be fed each account name to enable them on the new server. There must be a way to activate all CRMDatabase logons with the new server?
Could someone be kind enough to lead me through a step by step guide on the best solution.
I have one standby server that I use for multiple production DB SQL Server 2000 servers. We are upgrading one of the production SQL Servers to 2005. I will install 2005 on my standby and run 2000 and 2005 side by side.
Is this okay? Are there any caveats specific to running 2000 and 2005 on the same standby server?
I have moved my databases to 2000 to instance of 2005 on the same server. Now i set databases offline in 2000 as i did upgrade use backup & recovery method.
& my connection string Password=test;Persist Security Info=True;User ID=test;Initial Catalog=databasename;Data Source=ipaddress
i was using above connection string to connect when using 2000 databases form applications in the production machine
I get the following error when i am running my applications now after moving to 2005
An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)
IS it because i have two server on one server or What do i need to do in order to fix this....tried several thing by searching nothing worked out..
I know i can use the sentence SET IMPLICIT_TRANSACTIONS ON in a Stored Procedure to force SQL Server to set the connection into implicit transaction mode.
Have i a sentence or configuration to force all SQL Server connections to implicit transaction mode?
We have SQL server 2000 on windows 2000. From our desktop MS Access was connected to database through ODBC. Since yesterday (after our consultant had updated another asp application in the same server) we are getting €œSQL Server Error: 18452. €¦.. Login failed for user €˜(null)€™. Reason: not associated with a trusted SQL Server connection. €œ
The consultant saying he did not touch any settings on server (?). And the problem is even server€™s security property shows it has mixed mode authentication. But I cannot connect to server even through my SQL server enterprise manager in windows authentication mode. I can connect if I use SQL server authentication. Through ODBC I can connect also and test fine, if I use SQL authentication. But the Access application wouldn€™t connect using SQL authentication in ODBC.
So, can any one help me to find out what else could be done to make sure that the server is going to accept windows authentication. I€™m thinking any other settings or registry change €¦ etc. Please help.
I am moving my SQL 2000 Server from a Small Business Server to a full version of Windows 2000 Server and SQL 2000 Server. I have had no experience doing this but have backed up and restored my production databases for practice in case a of disaster situation. Is there anything special I need to do to move everything, including the system databases to a new server and not loose any of the user logons, etc.?
Hi there everyone, I have written a database system which tracks the performance of working in a shipping company in access. Im now rewriting the system in sqlserver and the only real problem I have found so far is that its difficult to estimate what kind of a server *cpu* & *ram* would be appropraite. The system currently performs transaction on my desktop machine in a second a quickest and 2 at slowest. There are going to be about 500 users in 3 time zones so there will only really be about 300 max hitting the system in an hour. I was looking at a Dell Poweredge server with twin P3's and half a Gb or ram would this be a good place to start from?
I have developed an Access 97 database that I would like to distribute to anumber of staff, but they do not have Access. At the same time I amconsidering upgrading to SBS 2003 premium edition which comes with SQLServer 2000.1. If we were to upgrade would it be a very difficult job to recreate thedatabase in SQL Server 2000, as in does it have wizards, macros etc.?2. Would the staff be able to use and share the new database from the serveror would they also require additional software on their desktops?3. Is there any way of distributing the Access 97 database with some sort of"run-time" licence - it was not developed using a developers edition?This has been posted to both comp.databases.ms-access andcomp.databases.ms-sqlserverYour advice would be appreciated.RegardsJohn McC
Being a very novice SQL Server administrator, I need to ask the experts a question.
How do I go about moving a database from 1 drive to another? The source drive (C is local to the server, but the target drive (E is on a Storage Area Network (SAN), although it is still a local drive for the server. I want to move the database from C: to E:. Can someone provide me with instructions?
We have a new failover cluster (Windows 2003 SP1, Microsoft SQL 2000 SP4) with each node of the cluster hosting 7 SQL Server instances in a 2-node active-active configuration connected to a SAN. We are planning to move some SQL Server Instances(from existing stand-alone servers) into this Cluster. Any insight into the process of moving SQL Servers into the cluster would be highly appreciated.
My old database server runs SQL 2000 and has the CRM 3.0 app and database, our corporate web site (SharePoint Services 3.0) database, and Project Server 2007 database. The corporate site and project apps and web sites reside on our file server.
I want to move, upgrade or migrate the databases, corporate site and Project site to this new SQL 2005 server. I am a little unsure the best way to do this.
Should I move all the database first, then move the apps?
Should I do a restore of everything on the new server, and after I know it works just turn off the other server?
I am applying hourly differential backup to the backup server from production with the following command. This command makes the database on standby server into read only mode.
RESTORE DATABASE ARSYSTEM FROM DISK = 'E:SQL backup from productionsql_full_backup' WITH MOVE 'arsystem' TO 'd:ardataarsystem.mdf' , MOVE 'arsystem_log' TO 'D:ARLOGARsystem' , STANDBY = 'E:SQL backup from productionSQL daily diff back up'
Now I want to run a command which will put the database in write mode. I have created a job which would make the datbase Write mode. This job runs successfully sometimes and fails sometimes. I need to ensure that the job always succeeds. When it fails, how do I troubleshoot and what is the possible fix?
Thanks in advance.
The error message is
Cannot apply the backup on device 'E:SQL backup from productionSQL daily diff back up' to database 'ARSYSTEM'. [SQLSTATE 42000] (Error 3136) RESTORE DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013). The step failed.
The steps for the job are as follows with the failing step highlighted in bold.
copy /y "\172.31.9.12Remedy BackupackupSQL backupsql_full_backup" "E:SQL backup from productionsql_full_backup"
copy /y "\172.31.9.12Remedy BackupackupSQL backupSQL daily diff back up" "E:SQL backup from productionSQL daily diff back up"
xp_cmdshell 'net stop "bmc remedy action request system server"'
exec rp_kill_db_processes 'ARSYSTEM'
RESTORE DATABASE ARSYSTEM
FROM DISK = 'E:SQL backup from productionsql_full_backup'
WITH
MOVE 'arsystem' TO 'd:ardataarsystem.mdf' ,
MOVE 'arsystem_log' TO 'D:ARLOGARsystem' ,
NORECOVERY
Failing step
RESTORE DATABASE ARSYSTEM
FROM DISK = 'E:SQL backup from productionSQL daily diff back up'
WITH
MOVE 'arsystem' TO 'd:ardataarsystem.mdf' ,
MOVE 'arsystem_log' TO 'D:ARLOGARsystem' ,
RECOVERY
xp_cmdshell 'del /f "E:SQL backup from productionsql_full_backup"'
xp_cmdshell 'del /f "E:SQL backup from productionsql daily diff back up"'
xp_cmdshell 'net start "bmc remedy action request system server"'
I have scheduled the following hourly diffential restore job too which never fails.
RESTORE DATABASE ARSYSTEM FROM DISK = 'E:SQL backup from productionsql_full_backup' WITH MOVE 'arsystem' TO 'd:ardataarsystem.mdf' , MOVE 'arsystem_log' TO 'D:ARLOGARsystem' , STANDBY = 'E:SQL backup from productionSQL daily diff back up' EXEC MASTER..XP_CMDSHELL 'del /f "E:SQL backup from productionSQL daily diff back up"'
I'm a newbie on SSIS and am trying to grasp my way through this.
I am trying to copy data from a Sql Server 2000 database to a simplified table in Sql Server 2005 database.
What I want is to move the data to a staging table, then drop the main table and rename the staging table to the main table, to minimize the down-time of the data. I can't get the workflow to work, because the staging table has to exist when I run the package. I thought I could use an "Execute SQL" task to generate the table before I would run the task, but that doesn't work. Am I going about this the wrong way? Is there an optimal solution to this problem so my data can be accessible as much as possible.