Can anyone post a working example of a vm configuration booting from a ZVOL device as primary disk. Let's say I create it like this:
SOLVED:
The following lines must be added to the configuration file:
With this config vm(8) will utilize zfs(8) to create a sparse volume (
zfs create -sV 100G -o volmode=dev "mypool/vm/myvm/disk0"
, how do I expose it in my vm configuration file?SOLVED:
The following lines must be added to the configuration file:
Code:
disk0_name="disk0"
disk0_dev="sparse-zvol"
disk0_type="virtio-blk"
With this config vm(8) will utilize zfs(8) to create a sparse volume (
volmode=dev
) used as virtio(4) device named disk0
under your vm dataset. Volume size can be adjusted with volsize=XY
afterwards.