![]() |
Now serving 104 guides. |
|
Migrate FreeBSD From One Harddrive To Another General Information This guide will explain how you can move your FreeBSD installation from one hard disk drive to another. I have done this many times using the dump/restore utility. Before you begin, be sure you have read this document carefully.Requirements
Configuration Let's assume that our FreeBSD installation is on a 4 gigabyte drive (ide master ad0) and we would like to move it to a new 20 gig drive.What you need to do is remove the old hard disk, install the new [20G] drive as an ide master and perform a minimal clean install of FreeBSD, setting up the partitions exactly how you want them. Be se sure to set the drive as bootable and boot from it one time as a test. Next, put your old [4G] drive back in the system as an ide master and the new [20G] drive in as an ide slave. Boot the system on your old installation in single user mode. To boot in single user mode press 4 at the 10 second countdown. At the (#) prompt type:
Author: ShadowBumble 6 Comments Posted by rhyous on March 06, 2007 at 5:22:04 pm EET
I followed this guide and it worked.
I was replacing an IDE drive with a SATA drive. So my new drive detected as /dev/ad4 even when it was the only drive and my IDE drive detected as /dev/ad0. The only step missing in this document was that I needed to replace all instances of ad0 with ad4 in /etc/fstab. The other thing I noticed is that for /, /var, /usr, only /var and /usr have soft-updates enabled on a default install. Is there a reason to enable soft-updates for /? Posted by rhyous on March 09, 2007 at 1:07:36 am EET
I also found that the tunefs commands are not needed. Newfs can set soft-updates with the -U parameter.
newfs /dev/ad1s1a newfs -U /dev/ad1s1e newfs -U /dev/ad1s1f Posted by ShadowBumble on March 22, 2007 at 9:23:45 am EET
I eddited the Guide with a little info that ofcourse you need to change all example names into the drive paths of you own harddrives this divers from which type and disc your using.
Posted by yourmother on April 19, 2007 at 6:25:30 pm EEST
Seems like a lot of extra work [and it may be justified, by I'm just missing it].
Why not just hook up the new drive, and then: - make new mount point on the original drive with /mnt as the root of the tree [for example, if you have /, /var, /usr and /home as mount points, you would create /mnt/var, /mnt/usr, /mnt/home as new mount points on the old drive.] - run sysinstall, create new FS on drive [be sure to set slice to bootable] and create partitions on the new drive according to the new plan [make a mountpoint of /, but change it to /mnt, then create partitions of /mnt/var, /mnt/usr, /mnt/home, all of equal or greater size than the originals]. - "Write" the changes to the new drive in sysinstall. Exist sysinstall, perform the dump/restore as above [newfs and everything has already been done]. - Edit /mnt/etc/fstab so that all mount points are appropriate for how you will be using the new drive [i.e., changing it from ad1 to ad0] - turn machine off, set new drive up as master [or whatever is appropriate], and reboot. Posted by rhyous on May 08, 2007 at 10:19:32 am EEST
That way works too. You should email the author the steps, and I am sure he would add/change the content for simplicity. If not, write up you own version of the guide.
Posted by ShadowBumble on May 16, 2007 at 10:35:07 am EEST
There are multiple ways to migrate and existing BSD installation to a new/bigger hard drive.
The way described by yourmother is also a very good and workable way, maybe simpler but the way i describe contains more info , maybe easier to follow for users doing it the first time or not too good familiar with BSD. Eitherway thanks yourmother for the information it can be contained as additional or informational on my guide. |
Copyright 2003 - 2008 BSD Guides. All rights reserved. |
About | Terms of Use | Privacy | Contact |

