Click here to monitor SSC
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in
Home       Members    Calendar    Who's On

Add to briefcase

How to fast reinstatement new data and objects on a copy of a irreparable database Expand / Collapse
Posted Tuesday, March 4, 2014 2:44 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Monday, May 25, 2015 11:17 PM
Points: 41, Visits: 142
One of our database have several failures, we cant repair it.
Actually all data and objects are available on the corrupted database.

We are using :
- sql server 2008 R2 (standard edition)
- recovery model : Simple
- compatibiliry level : SQL server 2005 (90)

Shemas replication scripts have been generated (using ssms) and we write a piece of code for migrating data between the old and a new database.

Our problem : We cant stop the old database during the copy.

My question, during the maintenance some data will be written to the old database.
What is the best/simple way to temporaly store this diferencial data for a post maintenance fast reinstatement ?

If there's a best way to duplicate this corrupt database using some tools or other prodcedures, your suggestions are welcome :)
Post #1547209
Posted Thursday, March 6, 2014 7:03 AM

SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Today @ 2:21 AM
Points: 977, Visits: 2,533
Whilst not my area of expertise I do have a couple of questions:

If the database has failed and you cannot repair and data will be written to the old database during your re-create surely the failures you have cannot be that bad if you can access all data and objects and still have the thing function?

What exactly are the problems your facing which lead you to say the database cannot be repaired?
Post #1548262
Posted Monday, March 10, 2014 8:06 AM
Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Tuesday, August 30, 2016 2:28 AM
Points: 3,034, Visits: 3,711
So you have a database that is saying it is corrupt, you have no certain way of knowing that you are not making the corruption worse because you are still updating it, and are worried about the downtime while you salvage what data is left.

My advice is to bite the bullet and schedule some downtime where you can copy out of your database everything that is still available.

You should also work out scripts that can check the new database for application integrity. The declared RI you have can deal with physical integrity and warn you of child records with missing parents, etc. However declarative RI cannot warn you if a parent has no children when your application expects that it should have.

Original author: SQL Server FineBuild 1-click install and best practice configuration of SQL Server 2016, 2014, 2012, 2008 R2, 2008 and 2005. 29 Aug 2016: now over 38,000 downloads.
Disclaimer: All information provided is a personal opinion that may not match reality.
Quote: "When I give food to the poor they call me a saint. When I ask why they are poor they call me a communist." - Archbishop Hélder Câmara
Post #1549242
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse