Menu

refind (0.12.0-1) bullseye with qemu

2021-09-03
2021-09-13
  • Marc Leeman

    Marc Leeman - 2021-09-03

    I am having 2 strange problems when running the combination of debian 11 (bullseye) in qemu with UEFI/refind.

    The first one is that, contrary to the versions in debian 10, I cannot boot the system anymore without attaching a graphics environment to it. The system just gives me a screen dump and refuses to boot.

    sudo qemu-system-x86_64 -enable-kvm -drive if=pflash,format=raw,readonly,file=/usr/share/OVMF/OVMF_CODE.fd -drive if=pflash,format=raw,file=./bullseye-unstable-1.04.12-amd64-20210903-114025.nvars.fd -drive format=qcow2,file=./bullseye-unstable-1.04.12-amd64-20210903-114025.qcow2 -drive format=qcow2,file=ssd-disk.qcow2 -device e1000,netdev=net0,mac=52:54:82:8b:e9:ed -netdev tap,id=net0 -device e1000,netdev=net1,mac=52:54:4f:84:9c:24 -netdev tap,id=net1 -m 4G -cpu host -smp 2
    

    add the -nographic flag and the system, and the system is drops a shell dump.

    13:36:28  [2J[01;01H[=3h[2J[01;01H[2J[01;01H[=3h[2J[01;01H[2J[01;01H[=3h[2J[01;01H[0m[35m[40m[2J[01;01H[=3h[2J[01;01H[0m[37m[40m!!!! X64 Exception Type - 0D(#GP - General Protection) CPU Apic ID - 00000000 !!!! 
    13:36:28  ExceptionData - 0000000000000000 
    13:36:28  RIP - 00000000BFF1411A, CS - 0000000000000038, RFLAGS - 0000000000010206 
    13:36:28  RAX - 0000000000000004, RCX - 0000000000000010, RDX - 0000000000000002 
    13:36:28  RBX - AFAFAFAFAFAFAFAF, RSP - 00000000BFF039C0, RBP - 00000000BFF03A9C 
    13:36:28  RSI - 00000000BFF03A9C, RDI - AFAFAFAFAFAFAFAF 
    13:36:28  R8 - 0000000000000002, R9 - 0000000000000000, R10 - 0000000000000000 
    13:36:28  R11 - 0000000000000C80, R12 - 00000000BFF03B68, R13 - 00000000BE370C80 
    13:36:28  R14 - 00000000BE36F100, R15 - 00000000BFF03B60 
    13:36:28  DS - 0000000000000030, ES - 0000000000000030, FS - 0000000000000030 
    13:36:28  GS - 0000000000000030, SS - 0000000000000030 
    13:36:28  CR0 - 0000000080010033, CR2 - 0000000000000000, CR3 - 00000000BFC01000 
    13:36:28  CR4 - 0000000000000668, CR8 - 0000000000000000 
    13:36:28  DR0 - 0000000000000000, DR1 - 0000000000000000, DR2 - 0000000000000000 
    13:36:28  DR3 - 0000000000000000, DR6 - 00000000FFFF0FF0, DR7 - 0000000000000400 
    13:36:28  GDTR - 00000000BFBEE698 0000000000000047, LDTR - 0000000000000000 
    13:36:28  IDTR - 00000000BF2A2018 0000000000000FFF, TR - 0000000000000000 
    13:36:28  FXSAVE_STATE - 00000000BFF03620 
    13:36:28  !!!! Find image based on IP(0xBFF1411A) /build/edk2-fUa9k0/edk2-0~20181115.85588389/Build/OvmfX64/RELEASE_GCC49/X64/MdeModulePkg/Core/Dxe/DxeMain/DEBUG/DxeCore.dll (ImageBase=00000000BFF04000, EntryPoint=00000000BFF062A0) !!!! 
    

    This is annoying for automated testing and integration.

    However, the major nuisance, and I've not been able to resolve this or debug it, is that a system that was installed with a debian installler iso file does not seem to boot anymore with refind, using the same command line as above, while performing exactly the same install/script with buster does allow the system to boot and a real HW system (installed with the same iso file) does boot with refind (both buster and bullseye).

    Actually, small correction, it boots with refind (as it shows the background, cf. config), but it does not show the menu, nor does it perform any action.

    menuentry "Linux A" {
        icon     /EFI/refind/icons/os_debian.png
        volume   boot_a
        loader   /vmlinuz-5.10.0-8-amd64
        initrd   /initrd.img-5.10.0-8-amd64
        options  "root=/dev/mapper/dsk00-root_a ro quiet consoleblank=0 fsprotect fsck.mode=skip console=ttyS0 reboot=pci"
    }
    
    banner banner.png
    banner_scale fillscreen
    default_selection "Linux A,"
    

    One small modification I needed to do (while porting for bullseye), was to add the slash in front of the loader/initrd (was not needed in buster) to get it to boot on hardware with debian 11 and a small fix to the installer script [1].

    However after booting the same system (so installed with debian netinst/refind/no-grub), installing grub in rescue mode (grub-mkdconfig, grub-install), does allow to boot the system (using grub).

    This only happens in bullseye (debian 11), not in buster (debian 10).

    [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=991945

     
  • Marc Leeman

    Marc Leeman - 2021-09-07

    This seems to be a regression between 0.11.3 and 0.12.0, more information can be found here:

    https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=993593

     
  • dakanji

    dakanji - 2021-09-10

    This seems to be a regression between 0.11.3 and 0.12.0,

    Why report a bug in v0.12.0 which is 3 releases out of date?

    rEFInd v0.12.0: Release Date 13 Mar 2020
    rEFInd v0.13.0: Release Date 15 Feb 2021
    rEFInd v0.13.1: Release Date 24 Feb 2021
    rEFInd v0.13.2: Release Date 13 Mar 2021

     

    Last edit: dakanji 2021-09-10
  • Marc Leeman

    Marc Leeman - 2021-09-13

    For a number of reasons:

    1. I encountered this during system upgrade from an OS (buster to bullseye)
    2. This OS is run (in our environment) on different architectures, and on different hardware (also virtual)
    3. There were config changes in refind, so it took me some time to figure those out
    4. The bug was not present on hardware, only in qemu, so again, I want to make certain that it was not something related to some other component
    5. refind 0.12 i now being shipped with Debian Bullseye for the following 2 years, reporting a bug like this against a version that is relevant for 2 years (at least) is very relevant: if not for a developer point of view, at the very least for a reference point: someone might encounter the same issue and have it identified by inspecting the forums or searching.
     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.