Bug 1228272

Summary: When using systemd-boot, dracut uses wrong target file
Product: [openSUSE] openSUSE Tumbleweed Reporter: Tilman Vogel <tilman.vogel>
Component: BootloaderAssignee: E-mail List <screening-team-bugs>
Status: NEW --- QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None    
Version: Current   
Target Milestone: ---   
Hardware: x86-64   
OS: openSUSE Tumbleweed   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Tilman Vogel 2024-07-24 10:07:08 UTC
When after an upgrade, 
  /usr/lib/module-init-tools/regenerate-initrd-posttrans 
runs 
  dracut -f --kver "$kver"
the generated initrd goes to
  /boot/efi/<somehexid>/$kver/initrd
which looks right but is in fact incorrect because
  /boot/efi/loader/entries/<somehexid>-$kver.conf
actually uses 
  initrd     /<somehexid>/$kver/initrd-$kver

Note the trailing "-$kver".

So, after running dracut, there are two initrds:
  /boot/efi/<somehexid>/$kver/initrd
  /boot/efi/<somehexid>/$kver/initrd-$kver
of which the former is the new one but ignored and the latter is an older one which will still be used.