Copying a FreeBSD install to a smaller disk
Chris Weiss
chris.weiss at gmail.com
Fri Sep 12 00:41:57 UTC 2008
How would I go about copying an existing FreeBSD installation to a smaller disk?
I've got a 3rd FreeBSD install I can boot from and store temporary
files on, all the disks are in the same hardware, so there's no
reconfiguration other than the boot device name and interface (IE
-SATA ad4 will become IDE ad0). The disk is partitioned using the
"default" sysinstall values and the contents of the larger disk will
fit on the smaller disk, although I need to increase the size of the /
and /var slices on the target to hold everything (/usr is fairly
empty, so it'll easily fit on the smaller disk).
For now, we'll say ad0 = new smaller disk, ad4 = boot BSD disk, and
ad6 = the BSD install I want to clone.
The path I've been going down is to manually partition and slice ad0
create ad4/mnt/source and ad4/mnt/target and mount /var, /tmp, etc
from ad0 and ad6 and manually copy the files. But I'm stuck on how to
handle /, since it'll have dev and proc and such.
Any thoughts on how to do this, or on a completely different approach?
I'm not aware of any 3rd party tools that'll deal with shrinking
FreeBSD partitions.
Thanks in advance for any help you folks can give!
--
-Chris
More information about the freebsd-questions
mailing list