Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Backup and Restore of Entire SQL Server 2005 Instance


Backup and Restore of Entire SQL Server 2005 Instance

Author
Message
dso808
dso808
Valued Member
Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)

Group: General Forum Members
Points: 64 Visits: 164
Is there a way to backup and restore an ENTIRE SQL Server 2005 instance? I mean everything - user databases, system databases, the WHOLE database server (instance) itself.

My first guess was to simply just copy the entire "Microsoft SQL Server" folder (the one located here - C:\Program Files\Microsoft SQL Server) and use that. But a coworker told me that they heard from someone that that may work but it was not a fool-proof method and may miss things and cause other problems.

So how should I do this? I just need a simple, fast way of bringing a SQL Server instance back to life using a copy. Thanks in advance to all who reply!
dso808
dso808
Valued Member
Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)

Group: General Forum Members
Points: 64 Visits: 164
One more thing - the restore doesn't have to be right to the split second of failure or anything like that. No concerns over differentials, transaction logs, simple, full, etc. Just imagine that the server was taken off line for awhile, a copy was made, the server was then brought back-online but the SQL Server instance fails and the copy is used to rebuild it to it's pre-off-line state. Thanks again.
Sudeepta
Sudeepta
SSC-Enthusiastic
SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)SSC-Enthusiastic (188 reputation)

Group: General Forum Members
Points: 188 Visits: 189
I hope, I understand your requirement correctly. You need to backup all the databases in an instance (both system and user database).

You can configure the all database backup using SQL Server Management plan.

Here is a post on how to configure the same: http://ukganguly.spaces.live.com/blog/cns!3DBBCE0B87F1CF26!178.entry

The above post says how to backup all user databases using maintenance plan. You need to modify the step ix, choose all databases in place of all user databases.

Hope this may help.

Thanks & Regards,
Sudeepta.
http://twitter.com/skganguly
dso808
dso808
Valued Member
Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)

Group: General Forum Members
Points: 64 Visits: 164
Hi Sudeepta and thanks very much for your reply. I know about the maintenance plan and agree that it's a very useful tool for generating backups. However, I don't believe the maintenance plan provides the ability to restore all the databases at once - you'd have to individually restore EVERY database. With 20+ databases in our SQL Server instance, we'd like something that would be more automated. Also, we'd like the restore to include the instance itself - meaning that this restore plan would re-build everything from top to bottom.

That's why I was hoping that the idea of simply using a copy of the "Microsoft SQL Server" folder in the "c:\" drive would suffice. But again, I'd heard that that method wasn't fool-proof and could cause problems.

Does anyone else have anything to add? Thanks again Sudeepta and thanks in advance to anyone else who replys!
Clifton Collins
Clifton Collins
Valued Member
Valued Member (71 reputation)Valued Member (71 reputation)Valued Member (71 reputation)Valued Member (71 reputation)Valued Member (71 reputation)Valued Member (71 reputation)Valued Member (71 reputation)Valued Member (71 reputation)

Group: General Forum Members
Points: 71 Visits: 194
A) Shutdown all SQL services
B) Backup files and/or system
C) Export/backup associated registry items or the entire registry
D) Startup all SQL services

If you shutdown all SQL services and perform a full Windows backup including the system state then you can restore the entire system with the sql installation configuration.

If you shutdown all SQL services, copy all of the data files, (mdf, ndf and ldf), then you can restore to anywhere. If the instance is the same name then copy the data files to the new location and start the SQL services. If the instance is another name you will have to perform a few more tsql steps to synchronize the system to the data file name(s).

I have a vbs script that generates an xml document which includes the original path and file names for each database, then performs a sql shutdown. Next the document is used to copy the files including the mssql system database files to a backup location. Finally a sql startup is performed.

The vbs restore routine performs a sql shutdown, then reads the document and restores the files to their original path. Finally a sql startup is performed.

Clifton G. Collins III
Steve Jones
Steve Jones
SSC-Dedicated
SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)SSC-Dedicated (35K reputation)

Group: Administrators
Points: 35873 Visits: 18715
If this is for DR, you might not want to have this automated to that level. A DR server potentially will have a different name, different IP addressing, different drive locations, etc.

You can restore master/msdb to a new server once you've installed SQL Server. Then you can restore databases. Honestly restoring 20 dbs isn't that hard or time consuming. You connect multiple times with query windows and start each restore. Or you have a script to read the backup files and restore them, fix logins, etc.

There are companies that sell software to do a bare metal restore, including SQL Server and Windows, but I have not had great luck with them, precisely because of differences in hardware.

Another alternative is a physical to virtual conversion. That will copy everything and get you a complete duplicate, but remember that IP and Windows naming will be in conflict.

Follow me on Twitter: @way0utwestForum Etiquette: How to post data/code on a forum to get the best help
dso808
dso808
Valued Member
Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)

Group: General Forum Members
Points: 64 Visits: 164
Big thanks Clifton! I think this might be what the doctor ordered. Really appreciate it.
dso808
dso808
Valued Member
Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)Valued Member (64 reputation)

Group: General Forum Members
Points: 64 Visits: 164
Hi Steve and thanks for your input! This isn't for DR but I liked your solution for restoring the system DBs and then restoring the individual user DBs after installing the instance. Really appreciate your help - have a great day!
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search