With '-cpu host' in L1 nested guest fails: "KVM: entry failed, hardware error 0x7"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

This error occurs when using using '-cpu host'. And, is consistently
reproducible with Fedora 21's Kernels.


One way to reproduce the issue
------------------------------

a) Enable nested virt on host, I use this procedure[1]

b) Boot a a guest (ensure /dev/kvm character device shows up)
    
c) Invoke `libguestfs-test-tool` utility in L1 (which will run a QEMU
   appliance with -cpu host). You should see the failure in this log:

    ~/.cache/libvirt/qemu/log/guestfs-vegb4aor6a8d1r3e.log


QEMU CLI: 

[. . .]
2014-11-26 12:16:02.449+0000: starting up
LC_ALL=C PATH=/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/home/kashyapc/.local/bin:/home/kashyapc/bin:/usr/local/sbin:/usr/sbin:/sbin HOME=/home/kashyapc USER=kashyapc LOGNAME=kashyapc QEMU_AUDIO_DRV=none TMPDIR=/var/tmp /bin/qemu-kvm -name guestfs-vegb4aor6a8d1r3e -S -machine pc-i440fx-2.1,accel=kvm,usb=off -cpu host -m 500 -realtime mlock=off -smp 1,sockets=1,cores=1,threads=1 -uuid 27869b93-0b83-4b57-a909-9265c677d307 -nographic -no-user-config -nodefaults -device sga -chardev socket,id=charmonitor,path=/home/kashyapc/.config/libvirt/qemu/lib/guestfs-vegb4aor6a8d1r3e.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc,driftfix=slew -global kvm-pit.lost_tick_policy=discard -no-hpet -no-reboot -no-acpi -boot strict=on -kernel /var/tmp/.guestfs-1000/appliance.d/kernel -initrd /var/tmp/.guestfs-1000/appliance.d/initrd -append panic=1 console=ttyS0 udevtimeout=6000 udev.event-timeout=6000 no_timer_check acpi=off printk.time=1 cgroup_disable=memory root=/dev/sdb selinux=0 TERM=screen -device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2 -device virtio-scsi-pci,id=scsi0,bus=pci.0,addr=0x2 -device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x3 -drive file=/tmp/libguestfsenp1an/devnull1,if=none,id=drive-scsi0-0-0-0,format=raw,cache=writeback -device scsi-hd,bus=scsi0.0,channel=0,scsi-id=0,lun=0,drive=drive-scsi0-0-0-0,id=scsi0-0-0-0,bootindex=1 -drive file=/tmp/libguestfsenp1an/overlay2,if=none,id=drive-scsi0-0-1-0,format=qcow2,cache=unsafe -device scsi-hd,bus=scsi0.0,channel=0,scsi-id=1,lun=0,drive=drive-scsi0-0-1-0,id=scsi0-0-1-0 -chardev socket,id=charserial0,path=/tmp/libguestfsenp1an/console.sock -device isa-serial,chardev=charserial0,id=serial0 -chardev socket,id=charchannel0,path=/tmp/libguestfsenp1an/guestfsd.sock -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.libguestfs.channel.0 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x4 -msg timestamp=on
Domain id=2 is tainted: custom-argv
Domain id=2 is tainted: host-cpu
KVM: entry failed, hardware error 0x7
RAX=000000000000000f RBX=0000000000000000 RCX=000000000000038f RDX=0000000000000000
RSI=000000000000000f RDI=000000000000038f RBP=ffff88001ee4faa0 RSP=ffff88001ee4faa0
R8 =0000000000000000 R9 =ffff88001f00cf60 R10=ffff88001ee4fa48 R11=0000000000000005
R12=000000000000038f R13=ffffffff81809390 R14=0000000000000000 R15=ffff88001f00ca40
RIP=ffffffff8105b8ca RFL=00000046 [---Z-P-] CPL=0 II=0 A20=1 SMM=0 HLT=0
ES =0000 0000000000000000 ffffffff 00c00000
CS =0010 0000000000000000 ffffffff 00a09b00 DPL=0 CS64 [-RA]
SS =0000 0000000000000000 ffffffff 00c00000
DS =0000 0000000000000000 ffffffff 00c00000
FS =0000 0000000000000000 ffffffff 00c00000
GS =0000 ffff88001f000000 ffffffff 00c00000
LDT=0000 0000000000000000 ffffffff 00c00000
TR =0040 ffff88001f012080 00002087 00008b00 DPL=0 TSS64-busy
GDT=     ffff88001f00a000 0000007f
IDT=     ffffffffff56b000 00000fff
CR0=8005003b CR2=00000000ffffffff CR3=0000000001c11000 CR4=000007f0
DR0=0000000000000000 DR1=0000000000000000 DR2=0000000000000000 DR3=0000000000000000 
DR6=00000000ffff0ff0 DR7=0000000000000400
EFER=0000000000000d01
Code=20 48 89 f8 48 09 f0 5d c3 90 55 89 f0 89 f9 48 89 e5 0f 30 <31> c0 5d c3 66 90 55 89 f9 48 89 e5 0f 33 48 89 d7 89 c1 48 c1 e7 20 48 89 f8 48 09 c8 5d
[. . .]


I'll admit, with Fedora Rawhide Kernel, libvirt and QEMU versions I
could not reproduce the issue:

  $ uname -r; rpm -q qemu-system-x86 libvirt-daemon-kvm 
  3.18.0-0.rc6.git0.1.fc22.x86_64
  qemu-system-x86-2.2.0-0.1.rc1.fc22.x86_64
  libvirt-daemon-kvm-1.2.10-3.fc22.x86_64


There's an existing bug for Fedora, here[2]


[1] https://kashyapc.fedorapeople.org/virt/procedure-to-enable-nested-virt-on-intel-machines.txt
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1016748#c9 -- KVM: entry
    failed, hardware error 0x7 for nested kvm guest

-- 
/kashyap
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux