Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#1057257: seabios: qemu does not boot into linux

26 views
Skip to first unread message

Reinhard Karcher

unread,
Dec 2, 2023, 4:50:04 AM12/2/23
to
Package: seabios
Version: 1.16.3-2
Severity: important

* What led up to the situation?

Updating seabios to the version in sid.

* What exactly did you do (or not do) that was effective (or
ineffective)?
Starting qemu

* What was the outcome of this action?
Grub tried to boot into linux, but failed, reporting:
virtio_net virtiol: virtio: device uses modern interface but does not have
VIRTIO_F_VERSION_1

* What outcome did you expect instead?
Starting linux

*** End of the template - remove these template lines ***


-- System Information:
Debian Release: trixie/sid
APT prefers unstable
APT policy: (500, 'unstable'), (500, 'testing'), (101, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 6.5.0-5-amd64 (SMP w/8 CPU threads; PREEMPT)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8), LANGUAGE=de:en_US
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

-- no debconf information

Reinhard Karcher

unread,
Dec 2, 2023, 5:30:05 AM12/2/23
to
Some more information about the failed boot:
virtio_net virtio1: virtio: device uses modern interface but does not have
VIRTIO_F_VERSION_1
virtio_gpu virtio0: virtio: device uses modern interface but does not have
VIRTIO_F_VERSION_1
...
many lines from md
...
Gave up waiting for root file system device. Common problems
- Boot args (cat /proc/cmdline)
- Check rootdelay= (did the system wait long enough?)
- Missing modules (cat /proc/modules: Is /dev)
ALERT! /dev/vda9 does not exist. Dropping to a shell:

I found no disks in /dev

Michael Tokarev

unread,
Dec 2, 2023, 7:30:05 AM12/2/23
to
Control: tag -1 + moreinfo unreproducible

02.12.2023 12:43, Reinhard Karcher :
> Package: seabios
> Version: 1.16.3-2
> Severity: important
>
> * What led up to the situation?
>
> Updating seabios to the version in sid.
>
> * What exactly did you do (or not do) that was effective (or
> ineffective)?
> Starting qemu

One can start qemu in 100500 various ways. Unfortunately you failed to provide
the way you used to start it. Qemu definitely works here and boots linux fine.

/mjt

Reinhard Karcher

unread,
Dec 6, 2023, 10:00:05 AM12/6/23
to
I use 2 files:

#/bin/sh
sudo -A -i /usr/lib/qemu/virtiofsd --socket-path=/var/run/apollon-vhost-
fs.sock --shared-dir /opt/virtio --log-level error &
sudo -i ~reinhard/kvm-Laptop.core

and:
reinhard@apollon:~$ cat kvm-Laptop.core
#/bin/sh
qemu-system-x86_64 \
-enable-kvm -cpu host \
-smp 8 \
-m 4096 \
-nographic \
-device intel-hda -device hda-duplex \
-chardev socket,id=char0,path=/var/run/apollon-vhost-fs.sock \
-device vhost-user-fs-pci,chardev=char0,tag=apollonfs \
-object memory-backend-memfd,id=mem0,size=4096M,share=on \
-numa node,memdev=mem0 \
-net nic,macaddr=00:16:3E:48:79:E8,model=virtio -net tap,ifname=tap1,script=no
\
-usb \
-device usb-tablet \
-device usb-host,vendorid=0x0c4b,productid=0x9102 \
-object rng-random,filename=/dev/urandom,id=rng07 \
-drive file=/opt/kvm_laptop.img,if=virtio,cache=writeback,media=disk,format=raw
\
-cdrom /dev/cdrom \
-k de \
"$@"

Reinhard

Michael Tokarev

unread,
Dec 6, 2023, 4:40:05 PM12/6/23
to
06.12.2023 17:47, Reinhard Karcher :

> reinhard@apollon:~$ cat kvm-Laptop.core
> #/bin/sh
> qemu-system-x86_64 \
> -enable-kvm -cpu host \
> -smp 8 \
> -m 4096 \
> -nographic \
> -device intel-hda -device hda-duplex \
> -chardev socket,id=char0,path=/var/run/apollon-vhost-fs.sock \
> -device vhost-user-fs-pci,chardev=char0,tag=apollonfs \
> -object memory-backend-memfd,id=mem0,size=4096M,share=on \
> -numa node,memdev=mem0 \
> -net nic,macaddr=00:16:3E:48:79:E8,model=virtio -net tap,ifname=tap1,script=no
> \
> -usb \
> -device usb-tablet \
> -device usb-host,vendorid=0x0c4b,productid=0x9102 \
> -object rng-random,filename=/dev/urandom,id=rng07 \
> -drive file=/opt/kvm_laptop.img,if=virtio,cache=writeback,media=disk,format=raw
> \
> -cdrom /dev/cdrom \
> -k de \
> "$@"

With this command line, qemu (or seabios) will try to boot off vhost-user-fs-pci
device but will most likely fail. I dunno why it tries to boot out of unsupported
device, but this is what it does for me anyway, unless I also add `bootindex=-1'
to this device (to exclude it from boot).

Or if I move -drive line before vhost-user-fs-pci line, it also boots out of
"kvm_laptop.img" device, the same way as with adding bootindex=-1.

So I don't know once again how you actually start this.

And it just works for me after rearranging boot order in the above command line.

Seabios, as far as I can see, does not have any support of virtiofs whatsoever,
neither older nor last one. Seabios 1.16.3 does not have changes related to
virtio or vhost, it's mostly a bugfix release, so I've no idea how you managed
to relate this issue at hand with seabios update.

I don't know what to do here.

/mjt

Michael Tokarev

unread,
Dec 6, 2023, 4:50:05 PM12/6/23
to
02.12.2023 12:43, Reinhard Karcher :
> Package: seabios
> Version: 1.16.3-2
> Severity: important
>
> * What led up to the situation?
>
> Updating seabios to the version in sid.
>
> * What exactly did you do (or not do) that was effective (or
> ineffective)?
> Starting qemu
>
> * What was the outcome of this action?
> Grub tried to boot into linux, but failed, reporting:
> virtio_net virtiol: virtio: device uses modern interface but does not have
> VIRTIO_F_VERSION_1

This message comes from linux kernel. This has nothing to do with
bios, it is qemu <=> linux kernel communications, way after kernel
is loaded. There were quite a few mentions of this message on the
list, most of which dated 2017 when a few bugs with new virtio
interface were fixed in both kernel and qemu. But it is definitely
not bios.

I'm afraid you need to ask upstream qemu for help here, providing
actual working way to reproduce this. I booted numerous linuxes
this way just today, it all works.

/mjt
0 new messages