[libvirt] [PATCH RFC] qemu: caps: invalidate kvm capable qemu binaries on every restart

Peter Krempa pkrempa at redhat.com
Fri Jan 4 15:27:10 UTC 2019


On Fri, Dec 28, 2018 at 15:06:36 +0300, Nikolay Shirokovskiy wrote:
> If qemu binary exposes kvm then caps depends heavily on host state.
> We are already check explicitly some host features - kernel version,
> microcode version, nested flag state. This won't nesserily help if somebody
> change CPU on host. Let's instead invalidate such caps on every daemon

Well, that isn't something that happens regularly. Also usually in that
case the OS is reinstalled as well.

> restart. This makes kernel version and microcode version check
> excessive but nested flag is still need to be checked.
> 
> Cache invalidating on restart is archived by keeping list of
> binaries that whose caps cache was validated at least once.
> If binary in not yet validated and supports kvm then we need to
> invalidate it's caps cache.
> 
> Signed-off-by: Nikolay Shirokovskiy <nshirokovskiy at virtuozzo.com>
> ---
> 
> If the patch will be accepted then I'll send a patch which removes mentioned
> excessive checks also.

Well, the whole point of this is to shorten the startup time of the
daemon if nothing changed.

In some cases I would agree that we can do it on a host restart, but
dropping caches on daemon restart is too excessive. Also in that case
all caching on disk can be removed.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20190104/f8624ad2/attachment-0001.sig>


More information about the libvir-list mailing list