Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vm-bhyve ignoring zvol/custom disks on device.map? #539

Open
mfoacs opened this issue Dec 4, 2023 · 1 comment
Open

vm-bhyve ignoring zvol/custom disks on device.map? #539

mfoacs opened this issue Dec 4, 2023 · 1 comment

Comments

@mfoacs
Copy link

mfoacs commented Dec 4, 2023

I've been using vm-bhyve to manage Debian guest, with 2 additional custom disks.

The logs are show the configuration disks being correctly parsed and vm-bhyve creating the device.map on the fly before booting the vm:

Dec 04 21:31:59: booting

Dec 04 21:31:59: create file /zstorage/vm/xxxx-vm/device.map

Dec 04 21:31:59:  -> (hd0) /zstorage/vm/xxxx-vm/disk0.img

Dec 04 21:31:59:  -> (hd1) /dev/zvol/zdata/disk1

Dec 04 21:31:59:  -> (hd2) /dev/zvol/zstorage/vm/xxxx-vm/disk2

And that's correct, both volumes exist in the respective directories. However, the disks are not present on the vm initialization:

Dec 04 21:31:59: /usr/local/sbin/grub-bhyve -m /zstorage/vm/xxxx-vm/device.map -M 256G -r hd0,msdos1 xxxx-vm

Dec 04 21:32:05:  [bhyve options: -c 24 -m 256G -AHP -U xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx -u]

Dec 04 21:32:05:  [bhyve devices: -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/zstorage/vm/xxxx-vm/disk0.img -s 5:0,virtio-net,tap0,mac=xxxxxxxxxxxx]

Dec 04 21:32:05:  [bhyve console: -l com1,stdio]

Dec 04 21:32:05: starting bhyve (run 1)

And, naturally, the devices do not exist from within the guest.

The host is 14.0-RELEASE-p1.
vm-bhyve: Bhyve virtual machine management v1.5 (rev. 105102)

@mfoacs
Copy link
Author

mfoacs commented Dec 7, 2023

I confirm that I can start the vm manually with:

sudo /usr/local/sbin/grub-bhyve -m /zstorage/vm/xxxx-vm/device.map -M 256G -r hd0,msdos1 xxxx-vm ; sudo bhyve -c 24 -m 256G -AHP -U xxxxxxxxxxxxxxxx -u -s 0,hostbridge -s 31,lpc -s 4:0,virtio-blk,/zstorage/vm/xxxx-vm/disk0.img -s 6:0,virtio-blk,/dev/zvol/zdata/disk1 -s 7:0,virtio-blk,/dev/zvol/zstorage/vm/xxxx-vm/disk2 -s 5:0,virtio-net,tapX,mac=xxxx-xxxx-xxxx-xxxx -s 30,xhci,tablet -l com1,stdio xxxx-vm

The guest OS sees the disks and has full access to it.

Is this a limitation of vm-bhyve or there's something else going on?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant