On Thursday, 24 July 2025 23:18:55 British Summer Time Javier Martinez wrote:
> As suggestion:
> 
>  From the system that you use to chroot, use hwid software to get all 
> needed to boot.
> 
> Compile your own kernel without genkernel assuring that the options of 
> hwid are included in kernel (not as modules).
> 
> I never used dracut, grub allows specify the initramfs to use, use 
> genkernel for this.
> 
> Bootstrap is more nightmare than you can imagine, grub is a second stage 
> bootloader, you need one that should be u-boot. U-boot can include EFI 
> support or lack them. One uboot from X can be able to boot the grub you 
> made but the u-boot from Y don't.
> 
> I tried compile my own u-boot with my own bl31 but I was unable to make 
> it run.
> 
> This options are from the u-boot I built
> 
> # CONFIG_CMD_UUID is not set
> # CONFIG_CMD_FS_UUID is not set
> CONFIG_PARTITION_UUIDS=y
> CONFIG_LIB_UUID=y
> CONFIG_RANDOM_UUID=y
> 
> Can you be sure that your u-boot is able to find your partitions?
> By this reason firstly boot specify in kernel command line one 
> root=/dev/whateverdevices would.

If u-boot is involved (I wasn't aware of this) it must be configured to 
support the storage device(s) on which a bootable image (e.g. GRUB if used) is 
stored;  e.g.:

CONFIG_MMC=y

see here for more info:

https://docs.u-boot.org/en/latest/usage/spl_boot.html

u-boot can only boot certain types of image files, but if it is already 
configured to boot GRUB, then logically you only need to concern yourself with 
getting GRUB configuration working.


> Grub is something like that, their config can have more of less commands
> 
> as with the parameter: GRUB_DISABLE_LINUX_UUID
> 
> So my advice to you:
> 
> hwinfo from your live system to get your hardware info
> 
> If the u-boot calls grub, grub shall support initramfs done with 
> genkernel initramfs
> 
> Uboot for example require (at least mine) that kernel was uncompressed 
> and was unable to use genkernel initramfs, I had to do it with mkimage 
> (I did some scripts to make conversions) and with a limit in size kernel 
> and initramfs.
> 
> Compile your kernel without modules, get all, even firmware in kernel 
> image to be sure that the kernel itself without third party helpers (as 
> /usr/lib/firmware) are able to boot, discarding at this way the kernel 
> it self as cause of your misfortune.
> 
> /dev/root is a "link" to the real partition which is the root parameter 
> passed to the kernel in command line, you can see it using cat 
> /proc/cmdline, after that set it your self in grub config 
> root=/dev/mmcblk1p3 for example

I tend to specify the root fs UUID which unlike a block device's logical 
order, it does not change unless you reformat the partition.

root=UUID=XXXXX-XXXX-XXXX-XXXX-XXXXXXX

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to