Bug 1563669 - [RFE] change vdsm-hook-nestedvt so it requires UserDefinedVMProperty
Summary: [RFE] change vdsm-hook-nestedvt so it requires UserDefinedVMProperty
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: vdsm
Classification: oVirt
Component: Core
Version: 4.20.19
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
: ---
Assignee: Dan Kenigsberg
QA Contact: meital avital
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-04-04 12:21 UTC by Jiri Belka
Modified: 2018-04-05 04:52 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-04-05 04:52:43 UTC
oVirt Team: Virt
rule-engine: planning_ack?
rule-engine: devel_ack?
rule-engine: testing_ack?


Attachments (Terms of Use)

Description Jiri Belka 2018-04-04 12:21:49 UTC
Description of problem:

I had a host with 'kvm-intel.nested=1' set in one cluster but another cluster was tight on resources so I moved this host to other cluster (maintenance - edit - activate).

I forgot to unset this kernel cmd arg and thus later on VMs started on this newly moved host had '-cpu Westmere,vmx=on' added.

Later on, these VMs could not be migrated to other (long time added) hosts as these did not have 'kvm-intel.nested=1' set.

It seems to be odd that a kernel cmdline arg influences all VMs by default. Maybe it would be better to have a custom userdefinedvmproperty check in the hook, eg. use_nestedvt=(true|false), and only based on availability of this property and on 'kvm-intel.nested=1' arg presence on the host, the value 'vmx=on' would be added to particular VM.

This would make it explicit that a VM should have nested VT set - right now we can just guest, maybe it would have, maybe not, depending on which host it would start.

Version-Release number of selected component (if applicable):
4.2

How reproducible:
100%

Steps to Reproduce:
1. have a cluster with 2 hosts, only one with kvm-intel.nested=1 set
2. start a vm on the host with kvm-intel.nested=1
2b. move to other host
3. start a vm on the host without kvm-intel.nested=1
3b. move to other host


Actual results:
2b fails
3b works
we cannot say if a vm would support nested vt or not

Expected results:
nested vt should be defined explicli via property on the vm
when such vm starts, we know it has vmx set

Additional info:

LC_ALL=C PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin QEMU_AUDIO_DRV=spice /usr/libexec/qemu-kvm -name guest=lleistne-dwh,debug-threads=on -S -object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain-31-lleistne-dwh/master-key.aes -machine pc-i440fx-rhel7.3.0,accel=kvm,usb=off,dump-guest-core=off -cpu Westmere,vmx=on,vme=on,pclmuldq=on,x2apic=on,hypervisor=on,arat=on -m size=4194304k,slots=16,maxmem=16777216k...
...
warning: host doesn't support requested feature: CPUID.01H:ECX.vmx [bit 5]

Apr  4 13:51:58 slot-6b libvirtd: 2018-04-04 11:51:58.703+0000: 1614: error : virCPUx86UpdateLive:2727 : operation failed: guest CPU doesn't match specification: missing features: vmx

Comment 1 Michal Skrivanek 2018-04-04 13:11:02 UTC
you can see in Host detail page that nestedvt hook is installed or not

Comment 2 Jiri Belka 2018-04-04 13:23:11 UTC
(In reply to Michal Skrivanek from comment #1)
> you can see in Host detail page that nestedvt hook is installed or not

And you cannot see anything for a VM at all.

Comment 3 Michal Skrivanek 2018-04-05 04:52:43 UTC
correct. Still, I wouldn’t want to require any new manual per-VM configuration for nestedvt. Just deploy the hook to all hosts...


Note You need to log in before you can comment on or make changes to this bug.