restore(8)ing new / -- boots on metal but not in a VM

Alex Jurkiewicz alex at bluebottle.net.au
Mon Oct 12 09:37:16 UTC 2009


Hi all,
A little background: I'm writing a script that will allow me to
restore(8) a standard FreeBSD partition to multiple machines. So far,
I'm at the 'see if it works in principle' stage, and I'm finding
something strange.

My procedure:
* Start with an empty hard drive (ad0).
* Boot off the FreeBSD CD, enter the live CD filesystem shell (Fixit
-> Live CD Filesystem)
* Create a single slice with fdisk that spans the entire disk (fdisk
-i /dev/ad0)
* Create a single partition with bsdlabel that spans the entire slice
(bsdlabel -w /dev/ad0s1)
* Install the FreeBSD Boot Loader (boot0cfg -B /dev/ad0)
* Format and restore the dumpfile (newfs /dev/ad0s1a && mount
/dev/ad0s1a /mnt && cd /mnt && ssh storagebox "dd
if=home/aj/image.dump" | restore -rvf -
* Unmount /mnt and restart.

The steps work fine... on physical hardware. The restored image boots
up fine. As a VM guest, running in either VMWare or VirtualBox, it
don't work. Everything appears to go fine, but when I get to the boot
loader, pressing F1 just makes the PC speaker beep at me.

Any pointers would be appreciated. I'm using FreeBSD 6.4.

Cheers,
Alex Jurkiewicz


More information about the freebsd-questions mailing list