LXD VM disk passthrough

Hi,
I’m quiet new to LXD and trying to setup VMs using it to run k8s cluster.
My main requirement is to minimise storage virtualisation, and attach disks directly to the VMs, if possible, i.e. avoid creating storage pool, volume, and instead expose raw disk to vm.
I’ve couldn’t find information re. passthrough in docs, but, was able to add the disk to a vm using:

lxc config device add vm2 nvme9n1 disk source=/dev/nvme9n1 path=/dev/nvme9n1

When I lsblk inside vm2 I can see that the disk is indeed attached sdb 8:16 0 800G 0 disk.
Is this correct way of attaching disk to a VM?
Thanks.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.