Skip to main content.

2008-Mar-29

I wanted to test a sysinst fix. Installing in qemu or bochs is a little slow. gxemul is lot faster, but building sysinst with cross-compiler took too long. hubertf reminded me about vnd which is already detected by sysinst. First I created my image the wrong way:

dd if=/dev/zero of=sysinst.vnd.image bs=1 count=1 seek=1048576000

That is the wrong way because the sparse file later failed in disklabel with:

disklabel: ioctl DIOCWDINFO: Input/output error

So I created a 400 MB file and the vnode with the following:

dd if=/dev/zero of=~/tmp/sysinst.vnd.image bs=2048 count=204800
sudo vnconfig vnd0 sysinst.vnd.image

My built my custom src/distrib/utils/sysinst/ and ran it:

sudo ./arch/amd64/sysinst

sysinst gave choice of my wd0 (in use) or the vnd0. So I chose the vnode and could use it. If sysinst had it mounted I could look under /targetroot/. Or I could mount with:

sudo mount /dev/vnd0a /mnt

Also I could see the vnode and remove the vnode with:

sudo vnconfig -l

sudo vnconfig -u vnd0

By the way, I was doing this so I could fix a bug with rc.conf generation of the DHCP or manual network configuration. I used sysinst to install just base and etc sets using the local file system /usr/src/obj/releasedir.