Moving databases, including system ones, by copying and renaming partition

Hi, we have a copy of SQL Server 2000 running happily on a production server.

Unfortunately, we have realised that the server was set up wrongly, with the data partition (F) on the same Raid 1 drive as the operating system. We've been advised to move the data onto the currently-unused Raid 5 drives.

Our infrastructure team have offered to copy the files across, and rename the partitions so that the new partition is now the F drive.

Can anyone tell me if this would work?

Alternatively, I know there is a Knowledgebase article explaining how to detach and reattach each database, complete with additional steps for the system databases.

Could anyone please advise which of these options would be better/safer/less downtime etc.


more ▼

asked Nov 10, 2009 at 12:17 PM in Default

Helen gravatar image

11 1 1 1

(comments are locked)
10|1200 characters needed characters left

2 answers: sort oldest

As long as the SQL Server service is shut down during the operation, and the file names remain the same before and after, then you should be able to re-start without incident. To be honest, you don't really need to detach and re-attach if the files are going to be in the same locations afterwards as far as the file system is concerned. It won't really affect the time taken in doing so.

However, one thing you should definitely do is back up your databases first.

more ▼

answered Nov 10, 2009 at 12:35 PM

Matt Whitfield gravatar image

Matt Whitfield ♦♦
29.5k 61 65 87

I agree. It should work, but get a backup first. no sense in taking chances you don't need to.
Nov 12, 2009 at 12:51 PM Steve Jones - Editor ♦♦
(comments are locked)
10|1200 characters needed characters left

Personally i would detach/attach the databases instead of playing around with partitions. Just make sure you attach the databases as sa.

The MSKB you are looking on moving system databases is here.

more ▼

answered Nov 11, 2009 at 12:09 PM

nkav gravatar image

101 1 1 2

(comments are locked)
10|1200 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

New code box

There's a new way to format code on the site - the red speech bubble logo will automatically format T-SQL for you. The original code box is still there for XML, etc. More details here.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

SQL Server Central

Need long-form SQL discussion? SQLserverCentral.com is the place.



asked: Nov 10, 2009 at 12:17 PM

Seen: 1662 times

Last Updated: Nov 10, 2009 at 12:17 PM