I have found the qemu.conf file for the virtual machine I want to work with. However, whenever I modify the conf file and start the vm instance using “lxc start VMNAME”, the config file immediately reverts all changes.
For example, I want to change the following value:
I want “virtio-scsi-single” instead of “virtio-scsi-pci”.
Any guidance on how to correctly make this modification (or how to make QEMU startup option changes in general) within LXC/LXD would be great. Thank you.
That configuration file is generated by lxd/driver_qemu_templates.go at master · lxc/lxd · GitHub
As you can see, the driver = "virtio-scsi-pci" line is hardcoded there. The only other option is driver = "virtio-scsi-ccw".
It might be possible to add another device with raw.qemu something like
lxc config set VMNAME raw.qemu='-device virtio-scsi-single...'
I don’t know of any way to remove a device with raw.qemu.
I am hitting a strange issue (seemingly at random) where my ubuntu 20.04 VM will essentially lock up. If I am able to console in (which some times I can, sometimes I can’t), I see tons of “watchdog: BUG: soft lockup - CPU” messages and if I open htop, I always see a process (never the same process interesting), running the CPU to max like its stuck in an endless loop somehow.
I have searched and many have suggested it may be related to the scsi adapter being used. Specifically the values I need set are:
Hrm yeah so you’re running a kernel that has known severe issues with running LXD VMs.
I can’t say for certain the issue you’re experiencing is to do with that, but would seem prudent to wait until that is fixed before going further.