On Thu, 2024-05-30 at 14:45 +0200, Igor Mammedov wrote:
Usability of huge VMs (incl. large amount of vCPUs) heavily depends
on used guest OS. What would work for one might not work for other.
For general purpose OS adding IOMMU is typically necessary to make
vCPUs over 254 usable, for Windows adjusting -smp might make a
difference.
On the other hand, special built guest with tailored QEMU config
might
work without IOMMU just fine (David was the one who patched KVM to
that
effect if I recall correctly).
So, as far as I know, there is no way for any OS with any configuration
to bring up more than 255 vCPUs, without a vIOMMU.
IIUIC, it's a matter of number of bits available in the I/O APIC IRQ
destination register. Like, with only that available, and it being only
8 bit wide, it's just not doable.
In fact, even Linux is actually able to at least start... But it shows
the "[Firmware Bug]" lines and only has 255 online vCPUs, with no way
of bringing up the other ones (and I haven't stress tested a VM running
like that, so I don't know if it's also stable).
What I'm saying is that workload specific customization (guest
OS)
is not handled at libvirt layer.
FWIW, this seems more hardware than guest OS related to me...
It's typically upper layers which know what guest OS would be
and it's up to them to customize config to make sure that workload
would be able to use VM as intended.
Ok. But then why Libvirt does not let me define a VM with more than 255
vCPUs and no vIOMMU ?
I mean, basing on what you're saying, it seems that such should depend
(but, if yes, I'm not sure how....) on guest OS too... doesn't it?
Regards,
--
Dario Faggioli, Ph.D
http://about.me/dario.faggioli
Virtualization Software Engineer
SUSE Labs, SUSE
https://www.suse.com/
-------------------------------------------------------------------
<<This happens because _I_ choose it to happen!>> (Raistlin Majere)