Bug 1319673

Summary: qemu-kvm core dump with "-M rhel6.6.0" and "-cpu Westmere"
Product: Red Hat Enterprise Linux 7 Reporter: huiqingding <huding>
Component: qemu-kvm-rhevAssignee: Eduardo Habkost <ehabkost>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: high Docs Contact:
Priority: high    
Version: 7.3CC: chayang, huding, juzhang, knoel, virt-maint, xfu
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: qemu-kvm-rhev-2.5.0-4.el7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-11-07 21:01:58 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description huiqingding 2016-03-21 10:18:31 UTC
Description of problem:
Boot a vm with "-M rhel6.6.0" and "-cpu Westmere", qemu-kvm core dump.

Version-Release number of selected component (if applicable):
qemu-kvm-rhev-2.5.0-2.el7.x86_64
kernel-3.10.0-363.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. boot a guest with "-M rhel6.6.0" and "-cpu Westmere"
/usr/libexec/qemu-kvm \
-name rhel7 \
-S -machine rhel6.6.0,accel=kvm \
-m 2048 \
-cpu Westmere \
-realtime mlock=off \
-smp 4,maxcpus=4,sockets=4,cores=1,threads=1 \
-uuid 49a3438a-70a3-4ba8-92ce-3a05e0934608 \
-nodefaults \
-rtc base=utc,driftfix=slew \
-global kvm-pit.lost_tick_policy=discard \
-no-shutdown \
-global PIIX4_PM.disable_s3=1 \
-global PIIX4_PM.disable_s4=1 \
-boot order=c,menu=on,strict=on \
-device ich9-usb-ehci1,id=usb0,bus=pci.0,addr=0x5.0x7 \
-device ich9-usb-uhci1,masterbus=usb0.0,firstport=0,bus=pci.0,multifunction=on,addr=0x5 \
-device ich9-usb-uhci2,masterbus=usb0.0,firstport=2,bus=pci.0,addr=0x5.0x1 \
-device ich9-usb-uhci3,masterbus=usb0.0,firstport=4,bus=pci.0,addr=0x5.0x2 \
-device virtio-scsi-pci,id=scsi0,cmd_per_lun=234,bus=pci.0,addr=0x8 \
-device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x7 \
-drive file=/mnt/RHEL-Server-6.8-32-virtio.raw,if=none,id=drive-scsi-disk,format=raw,cache=writethrough,werror=stop,rerror=stop \
-device virtio-scsi-pci,id=scsi1,addr=0x13 \
-device scsi-hd,drive=drive-scsi-disk,bus=scsi1.0,id=data-disk2,bootindex=0 \
-chardev spicevmc,id=charchannel0,name=vdagent \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0 \
-chardev socket,id=charchannel1,path=/var/lib/libvirt/qemu/channel/target/rhel7.org.qemu.guest_agent.0,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=2,chardev=charchannel1,id=channel1,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0 \
-chardev spicevmc,id=charredir0,name=usbredir \
-device usb-redir,chardev=charredir0,id=redir0 \
-device usb-host,id=hostdev0 \
-net none \
-monitor stdio \
-qmp tcp:0:4466,server,nowait -serial unix:/tmp/ttym,server,nowait \
-device sga -spice port=5910,password=redhat-vga,disable-ticketing -vga qxl -global qxl-vga.ram_size=67108864 -global qxl-vga.vram_size=9437184
2.
3.

Actual results:
after step1, qemu-kvm core dump
(qemu) qemu-kvm: hw/core/qdev-properties.c:1065: qdev_prop_set_globals_for_type: Assertion `prop->user_provided' failed.

(gdb) bt
#0  0x00007ffff008d5f7 in raise () from /lib64/libc.so.6
#1  0x00007ffff008ece8 in abort () from /lib64/libc.so.6
#2  0x00007ffff0086566 in __assert_fail_base () from /lib64/libc.so.6
#3  0x00007ffff0086612 in __assert_fail () from /lib64/libc.so.6
#4  0x00005555558049d0 in qdev_prop_set_globals_for_type (typename=0x555556ad0700 "Westmere-x86_64-cpu", dev=0x555556bec000) at hw/core/qdev-properties.c:1065
#5  qdev_prop_set_globals (dev=0x555556bec000) at hw/core/qdev-properties.c:1080
#6  0x00005555558cfa8a in object_post_init_with_type (ti=0x555556b51e00, obj=0x555556bec000) at qom/object.c:325
#7  object_initialize_with_type (data=data@entry=0x555556bec000, size=76096, type=type@entry=0x555556b4d380) at qom/object.c:360
#8  0x00005555558cfc21 in object_new_with_type (type=0x555556b4d380) at qom/object.c:467
#9  0x00005555558cfc95 in object_new (typename=<optimized out>) at qom/object.c:477
#10 0x0000555555776a2a in cpu_x86_create (cpu_model=<optimized out>, errp=errp@entry=0x7fffffffd370) at /usr/src/debug/qemu-2.5.0/target-i386/cpu.c:2194
#11 0x0000555555738824 in pc_new_cpu (cpu_model=<optimized out>, apic_id=0, errp=errp@entry=0x7fffffffd3a0) at /usr/src/debug/qemu-2.5.0/hw/i386/pc.c:1065
#12 0x000055555573a7e9 in pc_cpus_init (pcms=pcms@entry=0x555556b8d800) at /usr/src/debug/qemu-2.5.0/hw/i386/pc.c:1146
#13 0x000055555573c43f in pc_init1 (machine=0x555556b8d800, pci_type=0x5555559c7983 "i440FX", host_type=0x55555597dec0 "i440FX-pcihost") at /usr/src/debug/qemu-2.5.0/hw/i386/pc_piix.c:143
#14 0x00005555556b9b69 in main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4543


Expected results:
Guest can be boot normally.

Additional info:
# lscpu
Architecture:          x86_64
CPU op-mode(s):        32-bit, 64-bit
Byte Order:            Little Endian
CPU(s):                32
On-line CPU(s) list:   0-31
Thread(s) per core:    2
Core(s) per socket:    8
Socket(s):             2
NUMA node(s):          1
Vendor ID:             GenuineIntel
CPU family:            6
Model:                 47
Model name:            Intel(R) Xeon(R) CPU E7- 4830  @ 2.13GHz
Stepping:              2
CPU MHz:               2129.000
BogoMIPS:              4255.85
Virtualization:        VT-x
L1d cache:             32K
L1i cache:             32K
L2 cache:              256K
L3 cache:              24576K
NUMA node0 CPU(s):     0-31

Comment 1 huiqingding 2016-03-21 10:19:29 UTC
I also test qemu-kvm-rhev-2.3.0-31.el7_2.10.x86_64 using the same command line of comment 0, the guest can boot normally.

Comment 3 Mike McCune 2016-03-28 22:33:16 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 4 Miroslav Rezanina 2016-04-01 14:40:00 UTC
Fix included in qemu-kvm-rhev-2.5.0-4.el7

Comment 6 huiqingding 2016-05-16 08:04:09 UTC
Reproduce this bug using the following version:
kernel-3.10.0-401.el7.x86_64
qemu-kvm-rhev-2.5.0-2.el7.x86_64

The command line is as comment 0, after step1, qemu-kvm core dump
(qemu) qemu-kvm: hw/core/qdev-properties.c:1065: qdev_prop_set_globals_for_type: Assertion `prop->user_provided' failed.

(gdb) bt
#0  0x00007ffff00a75f7 in raise () from /lib64/libc.so.6
#1  0x00007ffff00a8ce8 in abort () from /lib64/libc.so.6
#2  0x00007ffff00a0566 in __assert_fail_base () from /lib64/libc.so.6
#3  0x00007ffff00a0612 in __assert_fail () from /lib64/libc.so.6
#4  0x00005555558049d0 in qdev_prop_set_globals_for_type (typename=0x555556ad0700 "Westmere-x86_64-cpu", dev=0x555556bec000) at hw/core/qdev-properties.c:1065
#5  qdev_prop_set_globals (dev=0x555556bec000) at hw/core/qdev-properties.c:1080
#6  0x00005555558cfa8a in object_post_init_with_type (ti=0x555556b59c80, obj=0x555556bec000) at qom/object.c:325
#7  object_initialize_with_type (data=data@entry=0x555556bec000, size=76096, type=type@entry=0x555556b55200) at qom/object.c:360
#8  0x00005555558cfc21 in object_new_with_type (type=0x555556b55200) at qom/object.c:467
#9  0x00005555558cfc95 in object_new (typename=<optimized out>) at qom/object.c:477
#10 0x0000555555776a2a in cpu_x86_create (cpu_model=<optimized out>, errp=errp@entry=0x7fffffffd6e0) at /usr/src/debug/qemu-2.5.0/target-i386/cpu.c:2194
#11 0x0000555555738824 in pc_new_cpu (cpu_model=<optimized out>, apic_id=0, errp=errp@entry=0x7fffffffd710) at /usr/src/debug/qemu-2.5.0/hw/i386/pc.c:1065
#12 0x000055555573a7e9 in pc_cpus_init (pcms=pcms@entry=0x555556b8d800) at /usr/src/debug/qemu-2.5.0/hw/i386/pc.c:1146
#13 0x000055555573c43f in pc_init1 (machine=0x555556b8d800, pci_type=0x5555559c7983 "i440FX", host_type=0x55555597dec0 "i440FX-pcihost") at /usr/src/debug/qemu-2.5.0/hw/i386/pc_piix.c:143
#14 0x00005555556b9b69 in main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>) at vl.c:4543

Comment 7 huiqingding 2016-05-16 08:06:17 UTC
Verify this bug using the following version:
kernel-3.10.0-401.el7.x86_64
qemu-kvm-rhev-2.6.0-1.el7.x86_64

The command line is as comment 0, after step1, the guest can boot normally and run "dmesg", no error info.

Based on the above result, I think this bug has been fixed.

Comment 10 errata-xmlrpc 2016-11-07 21:01:58 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-2673.html