smbios parameter settings not visible in guest

Bug #1662345 reported by Ryan Harper
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
qemu (Ubuntu)
Confirmed
Medium
Unassigned
Xenial
Won't Fix
Medium
Unassigned
Bionic
Fix Released
Low
Unassigned

Bug Description

qemu-system-aarch64 supports -smbios parameters to export values into the DMI tables.
These values are viewable via /sys/class/dmi/id/* or via dmidecode (V3 tables).

Passing in custom values for things like -smbios type=1,manufacturer="Foobar" should result in that value being viewable in-guest via dmidecode or /sys/class/dmi/id/*

Testing with a Xenial qemu-system-arm and Xenial cloud-image shows that these smbios parameters aren't being modified.

ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: qemu-system-arm 1:2.5+dfsg-5ubuntu10.7
ProcVersionSignature: User Name 4.4.0-59.80-generic 4.4.35
Uname: Linux 4.4.0-59-generic aarch64
ApportVersion: 2.20.1-0ubuntu2.5
Architecture: arm64
Date: Mon Feb 6 16:09:03 2017
KvmCmdLine:
 COMMAND STAT EUID RUID PID PPID %CPU COMMAND
 kvm_arch_timer S< 0 0 63 2 0.0 [kvm_arch_timer]
 kvm-irqfd-clean S< 0 0 64 2 0.0 [kvm-irqfd-clean]
Lsusb: Error: command ['lsusb'] failed with exit code 1:
ProcEnviron:
 LANGUAGE=en_US:
 TERM=screen
 PATH=(custom, no user)
 LANG=en_US
 SHELL=/bin/bash
ProcKernelCmdLine: console=ttyS0,115200n8 ro
SourcePackage: qemu
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Ryan Harper (raharper) wrote :
Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Hi Ryan,
just to find if that is totally new or maybe bisect&backport - do you have any extra data on other "incarnation" of qemu?:
- new Qemu in Yakkety or Zesty-Proposed
- new Qemu in Debian
- Upstream

Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

I also saw that Dannf is subscribed already, are you looking into that?

Revision history for this message
Ryan Harper (raharper) wrote : Re: [Bug 1662345] Re: smbios parameter settings not visible in guest

On Tue, Feb 7, 2017 at 1:42 AM, ChristianEhrhardt <
<email address hidden>> wrote:

> Hi Ryan,
> just to find if that is totally new or maybe bisect&backport - do you have
> any extra data on other "incarnation" of qemu?:
> - new Qemu in Yakkety or Zesty-Proposed
> - new Qemu in Debian
> - Upstream
>
>
I don't have more info; I had seen emails to qemu-devel from 2015 for
arm64 and smbios parameters

https://lists.nongnu.org/archive/html/qemu-devel/2015-07/msg05404.html

These end up landing in Sep 2015, if I've found them properly:

commit 298fae38972cc0165415ead04b64bfcae55640d9
Merge: b597aa0 8d45c54
Author: Peter Maydell <email address hidden>
Date: Mon Sep 7 10:43:18 2015 +0100

    Merge remote-tracking branch
'remotes/pmaydell/tags/pull-target-arm-20150907' into s
taging

    target-arm queue:
     * cleanup to use g_new() and friends
     * support semihosting in A64
     * add SMBIOS support to mach-virt
     * remove hw_error() usages
     * fix bug in the AArch32:AArch64 register mapping
     * add a second PCI memory window in highmem on virt board
     * fix bug in arm_excp_unmasked()
     * add i.MX31 SoC
     * remove restriction on handling affinity values in virt board

> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1662345
>
> Title:
> smbios parameter settings not visible in guest
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1662345/+subscriptions
>

Revision history for this message
dann frazier (dannf) wrote :

I tested this at Ryan's request, and was using QEMU 1:2.6.1+dfsg-0ubuntu8 instantiated with the following command line:

sudo qemu-system-aarch64 -enable-kvm -m 4096 -cpu host -smp 8 -M virt,gic_version=host -nographic -pflash AAVMF_CODE.fd -pflash AAVMF_VARS.fd -drive if=none,file=disk.img,id=hd0 -device virtio-blk-device,drive=hd0 -netdev type=tap,id=net0 -device virtio-net-device,netdev=net0,mac=ac:67:de:d2:4b:06 -drive file=mini.iso,id=cdrom,if=none,media=cdrom -device virtio-scsi-device -device scsi-cd,drive=cdrom -smbios type=1,manufacturer="Foobar"

/sys/firmware/dmi is populated, but 'grep -ir Foobar /sys/class/dmi' returns nothing.

I don't have bandwidth right now to debug, but I can run tests if hw access is an issue.

Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

The commit Ryan found is in >=2.5 but the issue is seen in Xenial which is 2.5.
Also Dann tested the Yakkety version which seems to have the issue as well.

So there has to be more to it than we know yet.

Changed in qemu (Ubuntu):
status: New → Confirmed
importance: Undecided → Medium
Scott Moser (smoser)
tags: added: dsid
Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Clearing outdated bugs atm, lets be honest this is on no-ones prio list at all.
I'll set it to wishlist to reflect that.

tags: added: bot-stop-nagging
Changed in qemu (Ubuntu):
importance: Medium → Wishlist
Louis Bouchard (louis)
Changed in qemu (Ubuntu):
importance: Wishlist → Medium
assignee: nobody → Louis Bouchard (louis)
Changed in qemu (Ubuntu Xenial):
status: New → Confirmed
Changed in qemu (Ubuntu Bionic):
status: New → Fix Released
Changed in qemu (Ubuntu Xenial):
importance: Undecided → Medium
Changed in qemu (Ubuntu Bionic):
importance: Undecided → Low
Changed in qemu (Ubuntu Xenial):
assignee: nobody → Louis Bouchard (louis)
Revision history for this message
Louis Bouchard (louis) wrote :

Hello,
I have revived this bug and assigned myself to it.

It turns out that -smbios type=1,manufacturer=Scaleway is required by us to trigger cloud-init's DataSourceScaleway on our infrastructure.

And, moreover, the functionality works as designed on Bionic :

# dmidecode | head
# dmidecode 3.1
Getting SMBIOS data from sysfs.
SMBIOS 3.0.0 present.
Table at 0xBC030000.

Handle 0x0100, DMI type 1, 27 bytes
System Information
        Manufacturer: Scaleway
        Product Name: KVM Virtual Machine
        Version: 1.0
# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04 LTS
Release: 18.04
Codename: bionic
# arch
aarch64

So I am going to work on trying to identify what was added to version 1:2.11+dfsg-1ubuntu7.4 to make it work as expected.

Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Hi Louis,
I doubt you (or anyone) will still fix it for Xenial.
Feel free to update if that isn't true.

Changed in qemu (Ubuntu Xenial):
assignee: Louis Bouchard (louis) → nobody
Changed in qemu (Ubuntu):
assignee: Louis Bouchard (louis) → nobody
Changed in qemu (Ubuntu Xenial):
status: Confirmed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.