Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 27 Aug 1996 20:28:38 -0700 (PDT)
From:      Doug White <dwhite@gdi.uoregon.edu>
To:        Leonard Chung <leonard@pacbell.net>
Cc:        questions@FreeBSD.org
Subject:   Re: Moving FBSD to another HD?
Message-ID:  <Pine.BSI.3.94.960827202225.339K-100000@gdi.uoregon.edu>
In-Reply-To: <v01540b00ae49454f5f1b@[206.170.1.187]>

next in thread | previous in thread | raw e-mail | index | archive | help

On Tue, 27 Aug 1996, Leonard Chung wrote:

> I just got a new IDE HD, and would like to move FBSD from my old IDE HD to
> the new one to take advantage of the faster disk io.  Is there a
> (hopefully, easy :) way to do this?

I just went through this.  

1.  Run sysinstall on the new disk, set up the partitions as you like, and
just install the bin distribution (or select a strange dist like games and
let it fail).  This will set up the partitions and boot block.

2.  Reboot to the OLD copy of FreeBSD in single user mode, mount
partitions as normal (mount -u /;mount -a)

3.  Mount the new paritions one at a time.  Use a command like so to copy
the data:

cd /mnt  # or whatever the mountpoint is
tar cf - /filesystem | tar xf -   # replace '/filesystem' with the real FS
        			  # to copy

Use 'tar' since 'cp' if called with the wrong flags, will screw up the
permissions.  I had this unfortunate experience.  ;(

4.  If you want, edit /etc/fstab (saving a backup) to reflect the disk's
current config and boot it by typing "wd(1,a)/kernel" (or what's
appropriate) at the boot:  prompt.  This is to check that the copy worked
and the system will at least load the kernel. 

5.  Copy back the old fstab, move the disk into position, and boot up.

Backing up before starting is a *really* good idea, if you already do so.

Doug White                              | University of Oregon  
Internet:  dwhite@resnet.uoregon.edu    | Residence Networking Assistant
http://gladstone.uoregon.edu/~dwhite    | Computer Science Major




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSI.3.94.960827202225.339K-100000>