Bug 1705736
Summary: | VM with smbios type=host fails at "Don't know how to build fields for SMBIOS type 2". | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Siddhant Rao <sirao> |
Component: | qemu-kvm | Assignee: | Ademar Reis <areis> |
Status: | CLOSED NEXTRELEASE | QA Contact: | leidwang <leidwang> |
Severity: | high | Docs Contact: | |
Priority: | medium | ||
Version: | 7.9 | CC: | coli, dyuan, jinzhao, jortialc, jsuchane, juzhang, juzhou, lmen, meili, mkalinin, mtessun, mzhan, phrdina, tzheng, virt-maint, xiaodwan, xuwei, xuzhang |
Target Milestone: | rc | Keywords: | Reopened |
Target Release: | 7.9 | ||
Hardware: | x86_64 | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2020-10-22 11:57:20 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
Siddhant Rao
2019-05-02 20:33:20 UTC
During the manual insertion , I had changed the UUID as the UUID which is passed through cannot be same. I removed the UUID "4C4C4544-0035-4410-8052-C8C04F353432" which i had recieved from the "#virsh sysinfo" output and replaced it with "7a02085a-1012-45b4-8684-057bd7714a70" So the UUID in [1] and [2] are the same. [1] <domain type='kvm'> <name>abcd</name> <uuid>7a02085a-1012-45b4-8684-057bd7714a70</uuid> <memory unit='KiB'>2515968</memory> <currentMemory unit='KiB'>2515968</currentMemory> [2] <system> <entry name='manufacturer'>Dell Inc.</entry> <entry name='product'>PowerEdge R720</entry> <entry name='version'>Not Specified</entry> <entry name='serial'>H5DR542</entry> <entry name='uuid'>7a02085a-1012-45b4-8684-057bd7714a70</entry> <entry name='sku'>SKU=NotProvided;ModelName=PowerEdge R720</entry> <entry name='family'>Not Specified</entry> </system> So there are two issues: 1) if --sysinfo host is used virt-install creates correct XML with <smbios mode="host"/>, however, if this XML element is present libvirt doesn't check if QEMU present in the system supports type 0, 1, 2 and 3. That's the error message, QEMU in RHEL-7 is old 1.5.3 and it supports only type 0 and 1 so libvirt should not requiest type 2 or 3 unconditionally as that will fail with old QEMU. 2) if --sysinfo type=whatever is provided to virt-install it will ignore that non-existing type and it will silently change it to smbios, which is wrong and we should generate XML containing the non-existing type and libvirt fail with some decent error. I'll move this bug to libvirt and create a new one for virt-install. Can reproduce with qemu-kvm but not qemu-kvm-rhev. Reproduced Version: libvirt-4.5.0-16.el7.x86_64 qemu-kvm-1.5.3-164.el7.x86_64 virt-install-1.5.0-3.el7.noarch virt-manager-1.5.0-3.el7.noarch Reproduced Steps: 1. Prepare a guest with the following xml: ... <os> <type arch='x86_64' machine='pc-i440fx-rhel7.0.0'>hvm</type> <boot dev='hd'/> <smbios mode='host'/> </os> ... 2. Start the guest. # virsh start guest error: Failed to start domain guest error: internal error: process exited while connecting to monitor: qemu-kvm: -smbios type=2,manufacturer=HP,product=802E,version=KBC Version 05.22,serial=PESRKXACY8T05L: Don't know how to build fields for SMBIOS type 2 But can't reproduce it with qemu-kvm-rhev-2.12.0-27.el7.x86_64. So this may be also a qemu-kvm issue. The customer has reported that the following workaround fixed the problem and the case is closed now: ~~~ We were able to verify your workaround and we can confirm, that it works for us. At the end we were able to fulfill our needs by using --sysinfo system_manufacturer=XXX as a option to virt-install ~~~ We should consider it for RHEL8 or close the bug. Yes the workaround to manually insert the smbios into the XML works , However this should be working out of the Box when we use --sysinfo host we could target this for RHEL-8 if needed. We can reduce the severity of the Bug as well if needed. Per comment 3 there is nothing to be fixed in rhel-8, so I am closing this. If desired it has to be reopened and moved back to rhel-7 product. Reopening this bug in RHEL 7. The issue happens when specifying a baseboard information, which is the block 2 of SMBIOS. This is required by my customer as they run a software that queries the baseboard information, so the proposed workaround is not valid for me. Tested on versions: libvirt-4.5.0-36.el7_9.2.x86_64 libvirt-daemon-4.5.0-36.el7_9.2.x86_64 qemu-kvm-1.5.3-175.el7_9.1.x86_64 kernel-3.10.0-1160.2.1.el7.x86_64 Easily reproducible with this XML configuration: ~~~ <domain type='kvm'> <uuid>da1f922f-468e-4eba-8f7d-08fd1ae31246</uuid> <sysinfo type='smbios'> <bios> <entry name='vendor'>Dell Inc.</entry> <entry name='version'>2.8.0</entry> <entry name='date'>04/01/2020</entry> <entry name='release'>2.8</entry> </bios> <system> <entry name='manufacturer'>Dell Inc.</entry> <entry name='product'>PowerEdge R640</entry> <entry name='version'>Not Specified</entry> <entry name='serial'>5K1234</entry> <entry name='uuid'>da1f922f-468e-4eba-8f7d-08fd1ae31246</entry> <entry name='sku'>SKU=1234;ModelName=PowerEdge R640</entry> <entry name='family'>PowerEdge</entry> </system> <baseBoard> <entry name='manufacturer'>Dell Inc.</entry> <entry name='product'>12NR12</entry> <entry name='version'>A02</entry> <entry name='serial'>.5KT0B123.ABCDE000000001.</entry> <entry name='asset'>Not Specified</entry> </baseBoard> </sysinfo> <os> <type arch='x86_64' machine='pc-i440fx-rhel7.0.0'>hvm</type> <boot dev='hd'/> <smbios mode='sysinfo'/> </os> ~~~ libvirt log: 2020-10-15 06:58:54.466+0000: starting up libvirt version: 4.5.0, package: 36.el7_9.2 (Red Hat, Inc. <http://bugzilla.redhat.com/bugzilla>, 2020-07-22-09:25:36, x86-vm-25.build.eng.bos.redhat.com), qemu version: 1.5.3 (qemu-kvm-1.5.3-175.el7_9.1), kernel: 3.10.0-1160.2.1.el7.x86_64, hostname: rhel7.laptop.lab LC_ALL=C \ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin \ QEMU_AUDIO_DRV=spice \ /usr/libexec/qemu-kvm \ -name win2k19 \ -S \ -machine pc-i440fx-rhel7.0.0,accel=kvm,usb=off,dump-guest-core=off \ -cpu Broadwell-IBRS,+ibpb,+md-clear,+spec-ctrl,+ssbd,hv_time,hv_relaxed,hv_vapic,hv_spinlocks=0x1fff \ -m 2048 \ -realtime mlock=off \ -smp 2,sockets=2,cores=1,threads=1 \ -uuid da1f922f-468e-4eba-8f7d-08fd1ae31246 \ -smbios 'type=0,vendor=Dell Inc.,version=2.8.0,date=04/01/2020,release=2.8' \ -smbios 'type=1,manufacturer=Dell Inc.,product=PowerEdge R640,version=Not Specified,serial=5K1234,uuid=da1f922f-468e-4eba-8f7d-08fd1ae31246,sku=SKU=1234;ModelName=PowerEdge R640,family=PowerEdge' \ -smbios 'type=2,manufacturer=Dell Inc.,product=12NR12,version=A02,serial=.5KT0B123.ABCDE000000001.,asset=Not Specified' \ -no-user-config \ -nodefaults \ -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/domain-1-win2k19/monitor.sock,server,nowait \ -mon chardev=charmonitor,id=monitor,mode=control \ -rtc base=localtime,driftfix=slew \ -global kvm-pit.lost_tick_policy=delay \ -no-hpet \ -no-shutdown \ -global PIIX4_PM.disable_s3=1 \ -global PIIX4_PM.disable_s4=1 \ -boot strict=on \ -device ich9-usb-ehci1,id=usb,bus=pci.0,addr=0x5.0x7 \ -device ich9-usb-uhci1,masterbus=usb.0,firstport=0,bus=pci.0,multifunction=on,addr=0x5 \ -device ich9-usb-uhci2,masterbus=usb.0,firstport=2,bus=pci.0,addr=0x5.0x1 \ -device ich9-usb-uhci3,masterbus=usb.0,firstport=4,bus=pci.0,addr=0x5.0x2 \ -device virtio-serial-pci,id=virtio-serial0,bus=pci.0,addr=0x6 \ -drive file=/var/lib/libvirt/images/win2k19.qcow2,format=qcow2,if=none,id=drive-ide0-0-0 \ -device ide-hd,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0,bootindex=1 \ -netdev tap,fd=26,id=hostnet0 \ -device e1000,netdev=hostnet0,id=net0,mac=52:54:00:be:01:16,bus=pci.0,addr=0x3 \ -chardev pty,id=charserial0 \ -device isa-serial,chardev=charserial0,id=serial0 \ -chardev spicevmc,id=charchannel0,name=vdagent \ -device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=com.redhat.spice.0 \ -device usb-tablet,id=input0,bus=usb.0,port=1 \ -spice port=5900,addr=127.0.0.1,disable-ticketing,seamless-migration=on \ -vga qxl \ -global qxl-vga.ram_size=67108864 \ -global qxl-vga.vram_size=67108864 \ -global qxl-vga.vgamem_mb=16 \ -global qxl-vga.max_outputs=1 \ -device intel-hda,id=sound0,bus=pci.0,addr=0x4 \ -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 \ -chardev spicevmc,id=charredir0,name=usbredir \ -device usb-redir,chardev=charredir0,id=redir0,bus=usb.0,port=2 \ -chardev spicevmc,id=charredir1,name=usbredir \ -device usb-redir,chardev=charredir1,id=redir1,bus=usb.0,port=3 \ -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x7 \ -msg timestamp=on qemu-kvm: -smbios type=2,manufacturer=Dell Inc.,product=12NR12,version=A02,serial=.5KT0B123.ABCDE000000001.,asset=Not Specified: Don't know how to build fields for SMBIOS type 2 2020-10-15 06:58:54.651+0000: shutting down, reason=failed Hi, if the customer needs to specify baseboard information the only missing part to make it work is QEMU 1.5.3 not supporting SMBIOS type 2. Moving to QEMU as the support for SMBIOS type 2 was added in qemu-2.1.0 and there is nothing else to do in libvirt. Reproduce this bz on RHEL-7.9 and RHEL8.3.Not hit it on RHEL8.3 host, only hit it on RHEL7.9 host. 1. RHEL7.9 host env: kernel-3.10.0-1160.2.1.el7.x86_64 qemu-kvm-1.5.3-175.el7_9.1.x86_64 seabios-bin-1.11.0-2.el7.noarch qemu command: /usr/libexec/qemu-kvm \ -enable-kvm \ -nodefaults \ -machine pc,accel=kvm,usb=off,dump-guest-core=off \ -m 4G \ -smp 2 \ -cpu host \ -enable-kvm \ -smbios 'type=0,vendor=Dell Inc.,version=2.8.0,date=04/01/2020,release=2.8' \ -smbios 'type=1,manufacturer=Dell Inc.,product=PowerEdge R640,version=Not Specified,serial=5K1234,uuid=da1f922f-468e-4eba-8f7d-08fd1ae31246,sku=SKU=1234;ModelName=PowerEdge R640,family=PowerEdge' \ -smbios 'type=2,manufacturer=Dell Inc.,product=12NR12,version=A02,serial=.5KT0B123.ABCDE000000001.,asset=Not Specified' \ -device virtio-scsi-pci,id=scsi0,bus=pci.0 \ -drive file=rhel830-64-virtio-scsi.qcow2,format=qcow2,if=none,id=drive-scsi0-0-0-0,media=disk,cache=none,werror=stop,rerror=stop \ -device scsi-hd,bus=scsi0.0,drive=drive-scsi0-0-0-0,id=scsi0-0-0-0 \ -netdev tap,id=hostnet0,vhost=on,script=/etc/qemu-ifup,downscript=/etc/qemu-ifdown,queues=4 \ -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:dd:90:e9,bus=pci.0,vectors=10 \ -vnc :9 \ -device VGA \ -monitor stdio \ -qmp tcp:127.0.0.1:4444,server,nowait \ test result: [root@hp-dl385pg8-04 home]# sh smbios.sh qemu-kvm: -smbios type=2,manufacturer=Dell Inc.,product=12NR12,version=A02,serial=.5KT0B123.ABCDE000000001.,asset=Not Specified: Don't know how to build fields for SMBIOS type 2 Additional info: Test it with qemu-kvm-rhev-2.12.0-48.el7_9.1.x86_64,it works well,the smbios info is the same as we define in qemu command. 2.RHEL8.3 host env: kernel-4.18.0-240.el8.x86_64 qemu-kvm-5.1.0-13.module+el8.3.0+8382+afc3bbea.x86_64 seabios-1.14.0-1.module+el8.3.0+7638+07cf13d2.x86_64 qemu command: /usr/libexec/qemu-kvm \ -enable-kvm \ -nodefaults \ -machine pc,accel=kvm,usb=off,dump-guest-core=off \ -m 4G \ -smp 2 \ -cpu host \ -enable-kvm \ -smbios 'type=0,vendor=Dell Inc.,version=2.8.0,date=04/01/2020,release=2.8' \ -smbios 'type=1,manufacturer=Dell Inc.,product=PowerEdge R640,version=Not Specified,serial=5K1234,uuid=da1f922f-468e-4eba-8f7d-08fd1ae31246,sku=SKU=1234;ModelName=PowerEdge R640,family=PowerEdge' \ -smbios 'type=2,manufacturer=Dell Inc.,product=12NR12,version=A02,serial=.5KT0B123.ABCDE000000001.,asset=Not Specified' \ -device virtio-scsi-pci,id=scsi0,bus=pci.0 \ -drive file=rhel830-64-virtio-scsi.qcow2,format=qcow2,if=none,id=drive-scsi0-0-0-0,media=disk,cache=none,werror=stop,rerror=stop \ -device scsi-hd,bus=scsi0.0,drive=drive-scsi0-0-0-0,id=scsi0-0-0-0 \ -netdev tap,id=hostnet0,vhost=on,script=/etc/qemu-ifup,downscript=/etc/qemu-ifdown,queues=4 \ -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:dd:90:e9,bus=pci.0,vectors=10 \ -vnc :9 \ -device VGA \ -monitor stdio \ -qmp tcp:127.0.0.1:4444,server,nowait \ test result. Guest boot succussfuly,and smbios info is the same as we define in qemu command. (In reply to Pavel Hrdina from comment #14) > (In reply to Ademar Reis from comment #13) > > (In reply to Pavel Hrdina from comment #11) > > > Hi, if the customer needs to specify baseboard information the only missing > > > part to make it work is QEMU 1.5.3 not supporting SMBIOS type 2. > > > > > > Moving to QEMU as the support for SMBIOS type 2 was added in qemu-2.1.0 and > > > there is nothing else to do in libvirt. > > > > Pavel: can you please give me some pointer to where I can find more about > > support for SMBIOS type=2 support introduced in QEMU-2.1.0? I couldn't find > > anything in the release changelogs or anything explicit in git log. > > It was introduced by this patch series [1] and the respective commits are: > > c97294ec1b SMBIOS: Build aggregate smbios tables and entry point > 2e6e8d7a25 SMBIOS: Use bitmaps to prevent incompatible comand line options > cb36acb672 SMBIOS: Use macro to set smbios defaults > e41fca3da7 SMBIOS: Update header file definitions > e6667f719c SMBIOS: Rename symbols to better reflect future use > 7bf8ef196e E820: Add interface for accessing e820 table > > [1] <https://lists.nongnu.org/archive/html/qemu-devel/2014-04/msg03543.html> Thanks Pavel. This confirms that we can't support this in RHEL-7 (EUS already). Customers have to upgrade to RHEL-8 where this feature is present. |