From: Li Zhijian Subject: Re: [kvm-unit-tests] warning: host doesn't support requested feature: CPUID.01H:ECX.vmx [bit 5] Date: Mon, 21 Aug 2017 13:38:25 +0800 Message-ID: <386bb124-cd18-adb9-5491-7037b3dd9ec7@intel.com> References: <85823374-fbe4-50cd-060d-e0ebca4bd026@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, "Li, Philip" To: rkrcmar@redhat.com Return-path: Received: from mga01.intel.com ([192.55.52.88]:15950 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751064AbdHUFi3 (ORCPT ); Mon, 21 Aug 2017 01:38:29 -0400 In-Reply-To: <85823374-fbe4-50cd-060d-e0ebca4bd026@intel.com> Content-Language: en-US Sender: kvm-owner@vger.kernel.org List-ID: > >/Hi guys/ >// >/i encountered a problem when i test vmx related > cases/ >// >/the test log like below/ >/[adam@skylake kvm-unit-tests]$ > ./run_tests.sh/ >/SKIP vmx_null (0 tests)/ >/[adam@skylake > kvm-unit-tests]$ cat logs// >/SUMMARY vmx_null.log/ >/[adam@skylake > kvm-unit-tests]$ cat logs/vmx_null.log/ >/warning: host doesn't > support requested feature: CPUID.01H:ECX.vmx [bit 5]/ >/timeout -k 1s > --foreground 90s /usr/bin/qemu-system-x86_64 -nodefaults -device > pc-testdev -device isa-debug-exit,iobase=0xf4,iosize=0x4 -vnc none > -serial stdio -device pci-testdev -machine accel=kvm -kernel > x86/vmx.flat -smp 1 -cpu host,+vmx -append null # -initrd > /tmp/tmp.wTXf483ild/ >/enabling apic/ >/paging enabled/ >/cr0 = > 80010011/ >/cr3 = 469000/ >/cr4 = 20/ >/WARNING: vmx not supported, > add '-cpu host'/ >/SUMMARY: 0 tests/ >// >/why the test output this > warning, my skylake i5-6500 machine can support vmx feature, and how i > can fix it./ The warning means that KVM doesn't allow the guest to see > the vmx feature. You are most likely without nested vmx, because it is > disabled by default: % cat /sys/module/kvm_intel/parameters/nested N > In order to turn it on, reload the "kvm_intel" module with "nested=Y" > parameter. modprobe -r kvm_intel; modprobe kvm_intel nested=y Thank you very much, it works for me > If you want to have this automatically, add options kvm_intel nested=1 > to /etc/modprobe.d/kvm.conf. >/i tried the same test at my another > haswell(i7-4790) machine(has the same kernel) doesn't occur this > issue./ Not sure why it works on the other machine -- is it a > different distro? you are right, the skylake is Archlinux while the haswell is Ubuntu. Thanks Zhijian > Thanks.