Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[now un-solved] UEFI+UKI/initrd+LVM-raid1+systemd = confused
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
sMueggli
Guru
Guru


Joined: 03 Sep 2022
Posts: 486

PostPosted: Thu Oct 31, 2024 10:06 am    Post subject: Reply with quote

In which directory are you invoking dracut? From /usr/src/linux? Or from a directory where the "arch" folder does not exist?
Back to top
View user's profile Send private message
Nowa
Developer
Developer


Joined: 25 Jun 2014
Posts: 405
Location: Nijmegen

PostPosted: Thu Oct 31, 2024 10:36 am    Post subject: Reply with quote

Looking at the code in dracut, there is some cd'ing going on that I think is the cause of this problem. Though I don't quite understand why I cannot reproduce it on my end, probably I am not hitting the problematic cd before objcopy is run.

Anyway, please test this patch for dracut and let me know if it resolves your problem: https://github.com/dracut-ng/dracut-ng/pull/834
_________________
OS: Gentoo 6.10.12-gentoo-dist, ~amd64, 23.0/desktop/plasma/systemd
MB: MSI Z370-A PRO
CPU: Intel Core i9-9900KS
GPU: Intel Arc A770 16GB & Intel UHD Graphics 630
SSD: Samsung 970 EVO Plus 2 TB
RAM: Crucial Ballistix 32GB DDR4-2400
Back to top
View user's profile Send private message
m3101
n00b
n00b


Joined: 30 Oct 2024
Posts: 6
Location: Somewhere Under the Rainbow

PostPosted: Thu Oct 31, 2024 6:59 pm    Post subject: Reply with quote

Quote:
What filesystem are you using?


Ext4, no fancy LVM/RAID setups.
FAT32 for the EFI partition.

Quote:
In which directory are you invoking dracut? From /usr/src/linux? Or from a directory where the "arch" folder does not exist?


From /usr/src/linux

Invoking it with $(pwd)/arch instead of just the relative path works, oddly enough.

Quote:
Anyway, please test this patch for dracut and let me know if it resolves your problem: https://github.com/dracut-ng/dracut-ng/pull/834


Will do.
_________________
"We are a way for the universe to know itself." - Carl Sagan
Back to top
View user's profile Send private message
m3101
n00b
n00b


Joined: 30 Oct 2024
Posts: 6
Location: Somewhere Under the Rainbow

PostPosted: Thu Oct 31, 2024 7:19 pm    Post subject: Reply with quote

The new script seems to have fixed the issue!

Running the old one still yields the objcopy error, but the new one, pulled from https://github.com/Nowa-Ammerlaan/dracut-ng/tree/main, runs perfectly and yields a bootable working image for my system.

Parameters:
Code:
dracut --kver XXXX --kernel-image arch/x86/boot/bzImage --uefi --hostonly --fstab --kmoddir XXXX


Thanks for the agility, there. I'm used to stuff like this taking at the very least, a few weeks.
_________________
"We are a way for the universe to know itself." - Carl Sagan
Back to top
View user's profile Send private message
sMueggli
Guru
Guru


Joined: 03 Sep 2022
Posts: 486

PostPosted: Fri Nov 01, 2024 9:45 am    Post subject: Reply with quote

Do /lib/modules/XXXX/vmlinuz or /boot/vmlinuz-XXXX exist?
Back to top
View user's profile Send private message
m3101
n00b
n00b


Joined: 30 Oct 2024
Posts: 6
Location: Somewhere Under the Rainbow

PostPosted: Fri Nov 01, 2024 2:38 pm    Post subject: Reply with quote

Quote:
Do /lib/modules/XXXX/vmlinuz or /boot/vmlinuz-XXXX exist?


Nope. Neither of them.

/boot/vmlinuz-XXXX doesn't exist because I'm using /efi as the EFI partition, and I'm building a UKI, so I don't get a separate kernel and initramfs. It's a single .efi file.

Now /lib/modules/XXXX/vmlinuz I don't know about. Why should it be there?

Regardless, the problem is solved with Nowa's patch. It seems to have been an issue within dracut with relative paths.
_________________
"We are a way for the universe to know itself." - Carl Sagan
Back to top
View user's profile Send private message
sMueggli
Guru
Guru


Joined: 03 Sep 2022
Posts: 486

PostPosted: Fri Nov 01, 2024 2:55 pm    Post subject: Reply with quote

Because of "man 8 dracut":
Code:
       --kernel-image <file>
           Specifies the kernel image, which to include in the UEFI executable. The default is
           /lib/modules/<KERNEL-VERSION>/vmlinuz or /boot/vmlinuz-<KERNEL-VERSION>.
Back to top
View user's profile Send private message
Nowa
Developer
Developer


Joined: 25 Jun 2014
Posts: 405
Location: Nijmegen

PostPosted: Fri Nov 01, 2024 3:12 pm    Post subject: Reply with quote

m3101 wrote:

Now /lib/modules/XXXX/vmlinuz I don't know about. Why should it be there?


It exists if dist-kernels are used, we put a symlink there because the kernels rpm and deb packages have the kernel installed there and we like to have as much symmetry as possible in our gpkgs. You won't find this symlink for manually managed kernels.

Quote:
The new script seems to have fixed the issue!


Great! Thanks for testing! This fix has now been merged and will be in dracut 106+.
_________________
OS: Gentoo 6.10.12-gentoo-dist, ~amd64, 23.0/desktop/plasma/systemd
MB: MSI Z370-A PRO
CPU: Intel Core i9-9900KS
GPU: Intel Arc A770 16GB & Intel UHD Graphics 630
SSD: Samsung 970 EVO Plus 2 TB
RAM: Crucial Ballistix 32GB DDR4-2400
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum