I am struggling with VMs in Incus. The error message below indicates that I need kernel module vhost_vsock. I’m not sure how to add that kernel module.
I am running Debian built by Armbian for the Odroid HC4. Will I need to compile the kernel module myself since this is not a common platform?
Thanks in advance!
$ incus launch images:ubuntu/22.04 ubuntuVM --vm
Creating ubuntuVM
Error: Failed instance creation: Failed creating instance record: Instance type "virtual-machine" is not supported on this server: vhost_vsock kernel module not loaded
System info:
$ cat /etc/os-release
PRETTY_NAME="Armbian 23.11.1 bookworm"
NAME="Debian GNU/Linux"
VERSION_ID="12"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
HOME_URL="https://www.armbian.com"
SUPPORT_URL="https://forum.armbian.com"
BUG_REPORT_URL="https://www.armbian.com/bugs"
ARMBIAN_PRETTY_NAME="Armbian 23.11.1 bookworm"
$ incus version
Client version: 0.4
Server version: 0.4
$ uname -a
Linux odroidhc4 6.1.63-current-meson64 #1 SMP PREEMPT Mon Nov 20 10:52:19 UTC 2023 aarch64 GNU/Linux
$ sudo kvm-ok
INFO: /dev/kvm exists
KVM acceleration can be used
$ lsmod | grep vsock
$ lsmod | grep vhost
I found CONFIG_VHOST_VSOCK in /boot/config-6.1.63-current-meson64. Initially, the entry was not set. I have modified the entry to read CONFIG_VHOST_VSOCK=m. I then rebooted.
Maybe I missed an obvious implication of your previous reply, but I still have the same error that says vhost_vsock kernel module is not loaded.
$ lsmod | grep vhost
$ incus launch images:ubuntu/22.04 ubuntuVM --vm
Creating ubuntuVM
Error: Failed instance creation: Failed creating instance record: Instance type "virtual-machine" is not supported on this server: vhost_vsock kernel module not loaded
$ lsmod | grep vhost
$ sudo modprobe vhost
$ lsmod | grep vhost
vhost 53248 0
vhost_iotlb 16384 1 vhost
$ sudo modprobe vhost_vsock
modprobe: FATAL: Module vhost_vsock not found in directory /lib/modules/6.1.63-current-meson64
$ ls /lib/modules/6.1.63-current-meson64/kernel/drivers/
acpi base bluetooth char counter cxl dma firmware gpu hv i2c input mailbox mfd most net nvmem perf platform ptp reset scsi spmi target tty usb video w1
ata bcma bus clk cpufreq dax edac gnss hid hwmon i3c irqchip md misc mtd nfc pci phy power pwm rpmsg soc ssb thermal ufs vdpa virt watchdog
atm block cdrom connector crypto devfreq extcon gpio hsi hwtracing iio leds media mmc mux nvme peci pinctrl pps regulator rtc spi staging thunderbolt uio vhost virtio xen