Swapping hard drives

Eric McCoy emccoy at haystacks.org
Sun Mar 6 06:06:53 PST 2005


Ralph wrote:
> Hello folks
>   I'm looking to do a quick swap on a hard disk I currently have in my FreeBSD file-server.  It's an old 30Gb disk, and I've bought a nice, new big one to replace it.  The problem is, I'm not sure what the best way to do this is.  I have Samba shares on there, and other things, and as far as I'm concerned it's better if the system doesn't know [or care] that the disk is being swapped out, does that make sense?
>  
>   I guess what I'm asking is this, what's the best way to do a swap like this?

Put the new disk in your server, partition it "similarly" to the old 
disk, format, and copy over your data.  Then remove the old disk and 
reuse its connectors for your new disk (or just update /etc/fstab).  The 
idea is that your old filesystem is, say, /dev/ad2s1e.  That's what you 
want your new one to be.  All you need to do, really, is juggle IDE 
cables or SCSI IDs to make that happen.

You can also do an over-the-network copy, but that will obviously be 
much slower and requires two FreeBSD computers besides.



More information about the freebsd-questions mailing list