• [gentoo-user] Re: dracut seems confused about filesystem UUID data

    From Nuno Silva@21:1/5 to Michael on Thu Jul 24 17:50:01 2025
    On 2025-07-24, Michael wrote:

    On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke wrote:
    Dear gentoo folks :

    I am making very very slow progress with the SiFive P550 RISC-V
    board wherein I needed to get a GRUB bootloader from the Sifive Ubuntu
    flash image. I have no idea why the GRUB bootloader built inside the
    chroot stage 3 is a failure. That is a whole other problem for some
    other day. I am able to get the grub.cfg from /boot/grub/ directory on
    the root filesystem. I put it there manually.

    Once I get the GRUB menu and simply hit enter on the Gentoo linux
    menu item I get what looks like a bootable system .. until it is *not*.

    Thus :
    [snip ...]

    [ 229.478914] dracut Warning: Could not boot.


    dracut Warning: Could not boot.

    [ 229.517264] dracut Warning: /dev/disk/by-uuid/0AC0-79CF does not exist
    dracut Warning: [ 229.525221] dracut Warning:
    /dev/disk/by-uuid/d2821a3b-7ad0-44dc-989b-8b5b0c80b947 does not exist
    /dev/disk/by-uuid/0AC0-79CF does not exist
    dracut Warning: /dev/disk/by-uuid/d2821a3b-7ad0-44dc-989b-8b5b0c80b947
    does not exist

    Generating "/run/initramfs/rdsosreport.txt"
    You might want to save "/run/initramfs/rdsosreport.txt" to a USB stick
    or /boot
    after mounting them and attach it to a bug report.

    To get more debug information in the report,
    reboot with "rd.debug" added to the kernel command line.

    Dropping to debug shell.

    dracut:/#

    I have no idea where these strange UUID numbers are coming from. I was
    very careful to ensure the grub.cfg and the /etc/fstab were correct.

    Is there a trivial file somewhere that can be edited?

    The UUID 0AC0-79CF is from a DOS filesystem, most likely your ESP.

    The UUID d2821a3b-7ad0-44dc-989b-8b5b0c80b947 is from a linux fs. Most likely
    from your / partition.

    Run 'blkid' to find out which is which on your drive, or:

    ls -alF /dev/disk/by-uuid

    Grub will need this to know where it can pick up the initramfs.img.

    That specifically shouldn't be the problem, given that the output shows
    the bootloader loading that ramdisk as well as output from what ought to
    be the in-ramdisk system itself (notably "Dropping to debug shell."
    above)?

    --
    Nuno Silva

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Thu Jul 24 16:51:31 2025
    On Thursday, 24 July 2025 16:46:10 British Summer Time Nuno Silva wrote:
    On 2025-07-24, Michael wrote:
    On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke
    wrote:
    Dear gentoo folks :
    I am making very very slow progress with the SiFive P550 RISC-V

    board wherein I needed to get a GRUB bootloader from the Sifive Ubuntu
    flash image. I have no idea why the GRUB bootloader built inside the
    chroot stage 3 is a failure. That is a whole other problem for some
    other day. I am able to get the grub.cfg from /boot/grub/ directory on
    the root filesystem. I put it there manually.

    Once I get the GRUB menu and simply hit enter on the Gentoo linux

    menu item I get what looks like a bootable system .. until it is *not*.

    Thus :
    [snip ...]

    [ 229.478914] dracut Warning: Could not boot.


    dracut Warning: Could not boot.

    [ 229.517264] dracut Warning: /dev/disk/by-uuid/0AC0-79CF does not exist >> dracut Warning: [ 229.525221] dracut Warning:
    /dev/disk/by-uuid/d2821a3b-7ad0-44dc-989b-8b5b0c80b947 does not exist
    /dev/disk/by-uuid/0AC0-79CF does not exist
    dracut Warning: /dev/disk/by-uuid/d2821a3b-7ad0-44dc-989b-8b5b0c80b947
    does not exist

    Generating "/run/initramfs/rdsosreport.txt"
    You might want to save "/run/initramfs/rdsosreport.txt" to a USB stick
    or /boot
    after mounting them and attach it to a bug report.

    To get more debug information in the report,
    reboot with "rd.debug" added to the kernel command line.

    Dropping to debug shell.

    dracut:/#

    I have no idea where these strange UUID numbers are coming from. I was
    very careful to ensure the grub.cfg and the /etc/fstab were correct.

    Is there a trivial file somewhere that can be edited?

    The UUID 0AC0-79CF is from a DOS filesystem, most likely your ESP.

    The UUID d2821a3b-7ad0-44dc-989b-8b5b0c80b947 is from a linux fs. Most likely from your / partition.

    Run 'blkid' to find out which is which on your drive, or:

    ls -alF /dev/disk/by-uuid

    Grub will need this to know where it can pick up the initramfs.img.

    That specifically shouldn't be the problem, given that the output shows
    the bootloader loading that ramdisk as well as output from what ought to
    be the in-ramdisk system itself (notably "Dropping to debug shell."
    above)?

    Yes, you are quite right. I was thinking if Dennis is going to check through his installation he might as well check GRUB borrowed from Ubuntu too. -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmiCVoMACgkQseqq9sKV ZxmA2g/+O07B2hkD0w8YhcSe7ZxrZT+yMGjBocp2M1fvejNVGuiuHxL8W+pvQN5g QgJUXmOJ0Dx2CpcLnXcwRvfeaX69ZG6rdH/urZ45I1BeDh4tNgY8/6LSNLmCGN80 j9m1UQwXGjbuurLUE6u5etIJJ9SxVt2wSuV5/eEW/lO1Z5q9O3AER/TeMXAQfAWN zzG4IyHkyx1yyVMRtBk/XYSBLQRiN62AIYMQ4ljpndGyNlEyzBMIeUe34nGW8Tos 4kWD/th6WYwnkrxlurC5ykGpuKUxFo9HtWa7AFQh6rJLrOKEhvNQ3nAihL4hITTy qLwnPjFa//1r378LlH6Fn8dUifLf/GiVfapxFOy+BZ8VsW0dhzXUZCzCsVmEKF/D Ycy/8BJN0lUEWyawwINGWd+1vENBki2qJV7QWLOE5c7qPK+G7e43cpnPm+KCnA2c RAgIWTOPweqdaozTJdRIvlCte5TnHOO5tZ7lEiXCWkNbiiTtTmGJYX5ipf6fwPa0 NqXxrjAwQpB11I91B/jDqu7UaDBL4f6nwm0r3Tkiz+3j9/YLM8xBbHDdSrrZvXWd t6IHkbdHmh86Z5td7FaucmuNWqGplB99BTVOSpC950XX6SjVnKamQEKcgALXJPIO GfXn/Yj3Aa7Xqe9HkDIpdJ8ynTi/sXk+bCCPq4SUwXizGaKiEzM=
    =cy+b
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Dennis Clarke@21:1/5 to Michael on Thu Jul 24 18:50:01 2025
    On 7/24/25 11:51, Michael wrote:
    On Thursday, 24 July 2025 16:46:10 British Summer Time Nuno Silva wrote:
    On 2025-07-24, Michael wrote:
    On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke
    wrote:
    Dear gentoo folks :
    I am making very very slow progress with the SiFive P550 RISC-V


    <snip>


    That specifically shouldn't be the problem, given that the output shows
    the bootloader loading that ramdisk as well as output from what ought to
    be the in-ramdisk system itself (notably "Dropping to debug shell."
    above)?

    Yes, you are quite right. I was thinking if Dennis is going to check through his installation he might as well check GRUB borrowed from Ubuntu too.

    The GRUB situation is very strange.

    p550#
    p550# mount /dev/mmcblk0p3 /mnt/gentoo

    I did the emerge twice inside the chroot stage3 :

    p550#
    p550# grep -n 'completed' /mnt/gentoo/var/log/emerge.log | grep -i 'grub' 561:1753295980: ::: completed emerge (5 of 5) sys-boot/grub-2.12-r7 to / 610:1753297404: ::: completed emerge (6 of 6) sys-boot/grub-2.12-r7 to /
    p550#

    That results in a GRUB binary that is very different from the thing I
    stole from the SiFive Ubuntu flash stuff :

    p550#
    p550# ls -l /opt/gentoo_efi/EFI/gentoo/grubriscv64.efi
    -rwxr-xr-x 1 root root 159744 Jul 23 19:07 /opt/gentoo_efi/EFI/gentoo/grubriscv64.efi
    p550#
    p550# ls -l /mnt/mmc_efi/EFI/ubuntu/grubriscv64.efi
    -rwxr-xr-x 1 root root 3608576 Jul 16 13:06 /mnt/mmc_efi/EFI/ubuntu/grubriscv64.efi
    p550#

    Very different sizes there. The Ubuntu stuff is from 16th of July and
    seems to be at least twice as large. Could be more modules. No idea
    really.

    The GRUB that I built inside the stage3 chroot has never seen the light
    of day yet. It exists but I have not used it. It may be a better way
    to go here. For the moment just getting past this strange dracut UUID
    mixup seems reasonable.



    --
    --
    Dennis Clarke
    RISC-V/SPARC/PPC/ARM/CISC
    UNIX and Linux spoken

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Thu Jul 24 18:35:55 2025
    On Thursday, 24 July 2025 17:44:40 British Summer Time Dennis Clarke wrote:
    On 7/24/25 11:51, Michael wrote:
    On Thursday, 24 July 2025 16:46:10 British Summer Time Nuno Silva wrote:
    On 2025-07-24, Michael wrote:
    On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke

    wrote:
    Dear gentoo folks :
    I am making very very slow progress with the SiFive P550 RISC-V

    <snip>

    That specifically shouldn't be the problem, given that the output shows
    the bootloader loading that ramdisk as well as output from what ought to >> be the in-ramdisk system itself (notably "Dropping to debug shell."
    above)?

    Yes, you are quite right. I was thinking if Dennis is going to check through his installation he might as well check GRUB borrowed from Ubuntu too.
    The GRUB situation is very strange.

    p550#
    p550# mount /dev/mmcblk0p3 /mnt/gentoo

    I did the emerge twice inside the chroot stage3 :

    p550#
    p550# grep -n 'completed' /mnt/gentoo/var/log/emerge.log | grep -i 'grub' 561:1753295980: ::: completed emerge (5 of 5) sys-boot/grub-2.12-r7 to / 610:1753297404: ::: completed emerge (6 of 6) sys-boot/grub-2.12-r7 to / p550#

    That results in a GRUB binary that is very different from the thing I
    stole from the SiFive Ubuntu flash stuff :

    p550#
    p550# ls -l /opt/gentoo_efi/EFI/gentoo/grubriscv64.efi
    -rwxr-xr-x 1 root root 159744 Jul 23 19:07 /opt/gentoo_efi/EFI/gentoo/grubriscv64.efi
    p550#
    p550# ls -l /mnt/mmc_efi/EFI/ubuntu/grubriscv64.efi
    -rwxr-xr-x 1 root root 3608576 Jul 16 13:06 /mnt/mmc_efi/EFI/ubuntu/grubriscv64.efi
    p550#

    Very different sizes there. The Ubuntu stuff is from 16th of July and
    seems to be at least twice as large. Could be more modules. No idea
    really.

    Is there a reason you have borrowed the Ubuntu GRUB executable? I wouldn't
    min 'n match bootloader images. If you must try them both, try them one at a time.


    The GRUB that I built inside the stage3 chroot has never seen the light
    of day yet. It exists but I have not used it. It may be a better way
    to go here. For the moment just getting past this strange dracut UUID
    mixup seems reasonable.

    I suggest in the first instance you mount *all* necessary partitions and then follow the gentoo handbook to chroot into it. Once you are in the chroot'ed system you check GRUB_PLATFORMS="..." is set correctly for your platform's architecture, re-install GRUB, run 'dracut', before you finally run 'grub- mkconfig -o /boot/grub/grub.cfg' to generate GRUB's configuration.

    Exit, unmount and reboot to see what you get.

    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmiCbvsACgkQseqq9sKV Zxk1rQ/6AtuXdsBW3ArRLUpKc1jrvgeyXyiNMYkrD07aceJBbjOZKvNPU7flMbXS sGkTjOukIiAxnQESW/6GQalcNU+uols2kS+gRjn9hWN0A3UHAgt4HvHN7BiQaIx3 3+d5G4a6zG2FBYcAuXL1LZpPq+Krcdn5ZSNiMu60xdWXaR4B6JSSKFzOaT3jcudX 6v0f/sTdeQIx6vQgnte31CVREvdLuRskz+0+tENOhd3GOyC6ogz7UdnazV4M9gNx VG03CWH0RPePV5s1lCR+8cTpWDWS+Bz3osei8XLdI1Ss/3eTW8ik+OOMJz6+mXCO Fl/VvoXLW6bXizvXwILdBV3ecxDtTF7o4SHh8kuB4LJheD+9sBBRsNYzJtxKA5g3 VCNj/pbVyfmCUr5EAxz3aSeyVR60+0IApId5xxZOLNb5SWaBQkruTxZ8L8qy5Vcj XI1h/mnsM/NVd2b1A0d+eYWaqK97sHhG7M8m1I+i3S+hJVesg7+z9E2tG5h909uU 2X57vBrmqAXCxedHhCAB2EnLkhxvmUCuTyfveXn38HpcqIlhZxheN34mnQxG5QeK 9u2D1ZUC6ZnSd8gzt2BD1jPULaLn17Rxvgut7jizMVeh4QEK8GbNBq88ycypXf2w z6jvXzo/EtQ6Ruc+lf4XD6OMv1YhSogAWQimTqZU0UMRcZbZOCQ=
    =RVh1
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Dennis Clarke@21:1/5 to Michael on Thu Jul 24 22:00:02 2025
    On 7/24/25 13:35, Michael wrote:
    On Thursday, 24 July 2025 17:44:40 British Summer Time Dennis Clarke wrote:
    On 7/24/25 11:51, Michael wrote:
    On Thursday, 24 July 2025 16:46:10 British Summer Time Nuno Silva wrote: >>>> On 2025-07-24, Michael wrote:
    On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke


    <snip>

    The GRUB situation is very strange.

    p550#
    p550# mount /dev/mmcblk0p3 /mnt/gentoo

    I did the emerge twice inside the chroot stage3 :

    p550#
    p550# grep -n 'completed' /mnt/gentoo/var/log/emerge.log | grep -i 'grub'
    561:1753295980: ::: completed emerge (5 of 5) sys-boot/grub-2.12-r7 to /
    610:1753297404: ::: completed emerge (6 of 6) sys-boot/grub-2.12-r7 to /
    p550#

    That results in a GRUB binary that is very different from the thing I
    stole from the SiFive Ubuntu flash stuff :

    p550#
    p550# ls -l /opt/gentoo_efi/EFI/gentoo/grubriscv64.efi
    -rwxr-xr-x 1 root root 159744 Jul 23 19:07
    /opt/gentoo_efi/EFI/gentoo/grubriscv64.efi
    p550#
    p550# ls -l /mnt/mmc_efi/EFI/ubuntu/grubriscv64.efi
    -rwxr-xr-x 1 root root 3608576 Jul 16 13:06
    /mnt/mmc_efi/EFI/ubuntu/grubriscv64.efi
    p550#

    Very different sizes there. The Ubuntu stuff is from 16th of July and
    seems to be at least twice as large. Could be more modules. No idea
    really.

    Is there a reason you have borrowed the Ubuntu GRUB executable? I wouldn't min 'n match bootloader images. If you must try them both, try them one at a time.


    I tried to boot with the GRUB built within the chroot stage3. I was very careful to mount the correct FAT32 dos partition. The one on the board
    which appears as /dev/mmcblk0p1. However the board would not boot. It
    had some strange message and I did not record it.

    I guess I need to try that again.



    The GRUB that I built inside the stage3 chroot has never seen the light
    of day yet. It exists but I have not used it. It may be a better way
    to go here. For the moment just getting past this strange dracut UUID
    mixup seems reasonable.

    I suggest in the first instance you mount *all* necessary partitions and then follow the gentoo handbook to chroot into it. Once you are in the chroot'ed system you check GRUB_PLATFORMS="..." is set correctly for your platform's architecture, re-install GRUB, run 'dracut', before you finally run 'grub- mkconfig -o /boot/grub/grub.cfg' to generate GRUB's configuration.

    Exit, unmount and reboot to see what you get.

    A better question is "Why dracut"? Can I just build a kernel and then
    get an initramfs image file without the dracut stuff at all? Is this
    something really needed?


    --
    --
    Dennis Clarke
    RISC-V/SPARC/PPC/ARM/CISC
    UNIX and Linux spoken

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Jack@21:1/5 to Dennis Clarke on Fri Jul 25 00:10:02 2025
    On 2025.07.24 17:47, Dennis Clarke wrote:
    On 7/24/25 17:24, Javier Martinez wrote:
    Dennis

    You have reached to the trully nightmare of embeeded devices. How
    the
    hell can I boot this shoe box, I spent nearly 4 months in make
    rockpi
    boot.

    Have you thought in specify the rootfs by device instead by uuid?
    as in
    root=/dev/mmcblk0p3. If it works the trouble is that someone has not
    UUID support.

    I am indeed feeling the pain :/

    Here is what I find interesting about this bizarre little board :

    1) it has 32G of DDR5 memory

    2) when running the supplied Ubuntu image it is okay
    2.1) the supplied Ubuntu image does boot towards GRUB
    2.2) that GRUB uses a tiny grub.cfg which then points
    towards a much larger grub.cfg on the root fs

    3) I can flash the SiFive supplied Ubuntu onto the board
    and then boot and run that just fine.

    4) I can flash the Sifive supplied Yocto onto the board
    and then copy/backup all of that onto SATA disk and
    it will run entirely from the SATA disk just fine

    My initial testing shows the SiFive P550 board is around 75% of
    the speed we see in a Raspberry Pi 5. Most things. I tested with
    some libGMP and libMPFR stuff and also fairly abusive IEEE-754
    strict math stuff. It is about 75% the speed of the Rpi5. Sort of.

    Getting Gentoo nice and lean and mean onto this thing is not entirely
    a nightmare. More of a pain and frustration wherein the boot process
    is a damn mystery. Poorly documented to say the least.

    I also have had this board for about four months. It was dead and just powered off for at least a month because it would not boot anything. I
    had to curse and face east on a Tuesday when it was my mothers
    birthday
    under a full moon to get it to boot anything again. Much gnashing of
    teeth as they say.

    So here I am doing trial and error to figure out WTF works.

    I may post updates as I proceed. At the moment I am rebuilding the
    kernel with a USE flag that simply says "grub" :

    file /etc/portage/package.use/installkernel says

    sys-kernel/installkernel grub


    That may result in nothing much. I will take a look at whatever the
    Ubuntu /etc/fstab says. It baffles me. The Yocto image runs and mounts everything just fine with this :


    root@hifive-premier-p550:~# cat /etc/fstab
    # stock fstab - you probably want to override this with a machine
    specific one

    /dev/root / auto defaults 1 1
    proc /proc proc defaults 0 0
    devpts /dev/pts devpts mode=0620,ptmxmode=0666,gid=5 0 0
    tmpfs /run tmpfs mode=0755,nodev,nosuid,strictatime 0 0
    tmpfs /var/volatile tmpfs defaults 0 0

    # swap on the external SATA spinning disk UUID=ab60f3c4-7658-44f9-b944-139378afc9f6 none swap sw
    0 0
    root@hifive-premier-p550:~#
    root@hifive-premier-p550:~# cat /proc/swaps
    Filename Type Size
    Used Priority
    /dev/sda2 partition 4194300
    0 -2
    root@hifive-premier-p550:~#


    Well gee .... there is a bizarre /dev/root thing. I see nothing for
    UUID
    stuff other than swap.

    * baffled *

    Are any of those UUIDs in the errors present on the command line in
    grub.cfg?
    Are they present anywhere in the machine outside the chroot?
    Is there any chance at all you did the grub-mkconfig outside the chroot?

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Dennis Clarke@21:1/5 to Javier Martinez on Thu Jul 24 23:50:01 2025
    On 7/24/25 17:24, Javier Martinez wrote:
    Dennis

    You have reached to the trully nightmare of embeeded devices. How the
    hell can I boot this shoe box, I spent nearly 4 months in make rockpi
    boot.

    Have you thought in specify the rootfs by device instead by uuid? as in root=/dev/mmcblk0p3. If it works the trouble is that someone has not
    UUID support.

    I am indeed feeling the pain :/

    Here is what I find interesting about this bizarre little board :

    1) it has 32G of DDR5 memory

    2) when running the supplied Ubuntu image it is okay
    2.1) the supplied Ubuntu image does boot towards GRUB
    2.2) that GRUB uses a tiny grub.cfg which then points
    towards a much larger grub.cfg on the root fs

    3) I can flash the SiFive supplied Ubuntu onto the board
    and then boot and run that just fine.

    4) I can flash the Sifive supplied Yocto onto the board
    and then copy/backup all of that onto SATA disk and
    it will run entirely from the SATA disk just fine

    My initial testing shows the SiFive P550 board is around 75% of
    the speed we see in a Raspberry Pi 5. Most things. I tested with
    some libGMP and libMPFR stuff and also fairly abusive IEEE-754
    strict math stuff. It is about 75% the speed of the Rpi5. Sort of.

    Getting Gentoo nice and lean and mean onto this thing is not entirely
    a nightmare. More of a pain and frustration wherein the boot process
    is a damn mystery. Poorly documented to say the least.

    I also have had this board for about four months. It was dead and just
    powered off for at least a month because it would not boot anything. I
    had to curse and face east on a Tuesday when it was my mothers birthday
    under a full moon to get it to boot anything again. Much gnashing of
    teeth as they say.

    So here I am doing trial and error to figure out WTF works.

    I may post updates as I proceed. At the moment I am rebuilding the
    kernel with a USE flag that simply says "grub" :

    file /etc/portage/package.use/installkernel says

    sys-kernel/installkernel grub


    That may result in nothing much. I will take a look at whatever the
    Ubuntu /etc/fstab says. It baffles me. The Yocto image runs and mounts everything just fine with this :


    root@hifive-premier-p550:~# cat /etc/fstab
    # stock fstab - you probably want to override this with a machine
    specific one

    /dev/root / auto defaults
    1 1
    proc /proc proc defaults
    0 0
    devpts /dev/pts devpts
    mode=0620,ptmxmode=0666,gid=5 0 0
    tmpfs /run tmpfs mode=0755,nodev,nosuid,strictatime 0 0
    tmpfs /var/volatile tmpfs defaults
    0 0

    # swap on the external SATA spinning disk UUID=ab60f3c4-7658-44f9-b944-139378afc9f6 none swap sw 0 0 root@hifive-premier-p550:~#
    root@hifive-premier-p550:~# cat /proc/swaps
    Filename Type Size
    Used Priority
    /dev/sda2 partition 4194300
    0 -2
    root@hifive-premier-p550:~#


    Well gee .... there is a bizarre /dev/root thing. I see nothing for UUID
    stuff other than swap.

    * baffled *


    --
    --
    Dennis Clarke
    RISC-V/SPARC/PPC/ARM/CISC
    UNIX and Linux spoken

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Fri Jul 25 08:38:20 2025
    On Thursday, 24 July 2025 20:52:54 British Summer Time Dennis Clarke wrote:
    On 7/24/25 13:35, Michael wrote:

    I tried to boot with the GRUB built within the chroot stage3. I was very careful to mount the correct FAT32 dos partition. The one on the board
    which appears as /dev/mmcblk0p1. However the board would not boot. It
    had some strange message and I did not record it.

    I guess I need to try that again.

    If it is not too cryptic it will at least give you a hint as to what is
    missing in your system or its configuration.


    I suggest in the first instance you mount *all* necessary partitions and then follow the gentoo handbook to chroot into it. Once you are in the chroot'ed system you check GRUB_PLATFORMS="..." is set correctly for your platform's architecture, re-install GRUB, run 'dracut', before you
    finally run 'grub- mkconfig -o /boot/grub/grub.cfg' to generate GRUB's configuration.

    Exit, unmount and reboot to see what you get.

    A better question is "Why dracut"? Can I just build a kernel and then
    get an initramfs image file without the dracut stuff at all? Is this something really needed?

    On x86 arch you can build and embed anything and everything inside a kernel image these days, from microcode and firmware to encryption keys for filesystems. I do not know what your platform and arch requires. Dracut is just one relatively easy way to create an initramfs.

    From my ignorant point of view I think an initramfs *may be* necessary if its contents must be used as the only option to arrive at your storage devices;
    or, the hardware, block device, or filesystem drivers are not available in the secondary bootloader and you have to load these from an initramfs to be able
    to access the rootfs. A developed enough 1st or 2nd order bootloader would have the necessary drivers available to load the next stage, but with embedded devices storage space could be constrained.

    Studying forensically what ubuntu does will give you some idea what building blocks may be needed and how to configure them.
    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmiDNGwACgkQseqq9sKV Zxk+QA/7BEkHP6Lh+hBoBCGDid4V1uMEJDdaLxR4AEPyloOR7KEuIvSoAE0XIWoX Qwk2A93ok6qYbQoWmMvXLOX8oZ50HLm4iZf1JsmgiElM04mpNTdcvGkSH+8Fh2/L 3eTLAbjrkcziUvg+sDCXqU40nzli8jYz/CSL7sZBNJ0cxt/8H89ypLqviu0oaYkV r2JbW1HfMqUEnkr/DOr5hbSQtqatCMlVtKmcV/BARQFCSweW33FzV+DEXX23L1KE uCoilGaE/IlgxoD+tr4K36Ef45NwitzIltSvZD8E7eUOx38Ivyx5IGHWp7bnSr3y muis7GgrMI/MgqoXRL5X3ibgqW+BjZqy/e8foCXjs4RkXsWOREGMCEnWALNKSlo0 FWZVtnWCIjBMe6XhIq+2u9QUAtvkd266uwxSRhWPrCLybwWy2YL1E7B8NxfBG+Fw Uvb2wq9ClyX1fWTS0ZuY+GJKUteEUmVoXpoauhlvX4f1AQaKiMwgYMiQZbIs/Eaf /dTlhdqHEI8hSaHOyD1if/XTqGY/y6OWkDCCAjKjso/+WQaeWfTqyIFrgaprE/NK wuGbhnBCRGH+VwDxAaHHGzerPPCyoVxcbNcQwstFpjDvRi+CFvbfQqCs+i2Vf/yf aPgM7sjzQ1GkhWAVTn+3Ta4etvDbDnz+WRo2ZK6JV5mMpazo5wE=
    =OA+o
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Fri Jul 25 08:55:38 2025
    On Thursday, 24 July 2025 22:47:40 British Summer Time Dennis Clarke wrote:
    On 7/24/25 17:24, Javier Martinez wrote:
    Dennis

    You have reached to the trully nightmare of embeeded devices. How the
    hell can I boot this shoe box, I spent nearly 4 months in make rockpi boot.

    Have you thought in specify the rootfs by device instead by uuid? as in root=/dev/mmcblk0p3. If it works the trouble is that someone has not
    UUID support.

    I am indeed feeling the pain :/

    Here is what I find interesting about this bizarre little board :

    1) it has 32G of DDR5 memory

    2) when running the supplied Ubuntu image it is okay
    2.1) the supplied Ubuntu image does boot towards GRUB
    2.2) that GRUB uses a tiny grub.cfg which then points
    towards a much larger grub.cfg on the root fs

    3) I can flash the SiFive supplied Ubuntu onto the board
    and then boot and run that just fine.

    4) I can flash the Sifive supplied Yocto onto the board
    and then copy/backup all of that onto SATA disk and
    it will run entirely from the SATA disk just fine

    My initial testing shows the SiFive P550 board is around 75% of
    the speed we see in a Raspberry Pi 5. Most things. I tested with
    some libGMP and libMPFR stuff and also fairly abusive IEEE-754
    strict math stuff. It is about 75% the speed of the Rpi5. Sort of.

    Getting Gentoo nice and lean and mean onto this thing is not entirely
    a nightmare. More of a pain and frustration wherein the boot process
    is a damn mystery. Poorly documented to say the least.

    I also have had this board for about four months. It was dead and just powered off for at least a month because it would not boot anything. I
    had to curse and face east on a Tuesday when it was my mothers birthday
    under a full moon to get it to boot anything again. Much gnashing of
    teeth as they say.

    So here I am doing trial and error to figure out WTF works.

    I may post updates as I proceed. At the moment I am rebuilding the
    kernel with a USE flag that simply says "grub" :

    file /etc/portage/package.use/installkernel says

    sys-kernel/installkernel grub


    That may result in nothing much. I will take a look at whatever the
    Ubuntu /etc/fstab says. It baffles me. The Yocto image runs and mounts everything just fine with this :


    root@hifive-premier-p550:~# cat /etc/fstab
    # stock fstab - you probably want to override this with a machine
    specific one

    /dev/root / auto defaults
    1 1
    proc /proc proc defaults
    0 0
    devpts /dev/pts devpts mode=0620,ptmxmode=0666,gid=5 0 0
    tmpfs /run tmpfs mode=0755,nodev,nosuid,strictatime 0 0
    tmpfs /var/volatile tmpfs defaults
    0 0

    # swap on the external SATA spinning disk UUID=ab60f3c4-7658-44f9-b944-139378afc9f6 none swap sw 0 0 root@hifive-premier-p550:~#
    root@hifive-premier-p550:~# cat /proc/swaps
    Filename Type Size
    Used Priority
    /dev/sda2 partition 4194300
    0 -2
    root@hifive-premier-p550:~#


    Well gee .... there is a bizarre /dev/root thing. I see nothing for UUID stuff other than swap.

    * baffled *

    The '/dev/root' entry in fstab, or its alternative 'rootfs', represents a generic root fs device. You would/could use this if the root fs is on a pluggable device and its actual logical block device initialisation order and therefore name can change - e.g. from /dev/mmcblk0p2 to /dev/mmcblk0p3. /dev/ sda2, /dev/usb4 or whatever. Alternatively, you should be able to specify the fs UUID, or the partition PARTUUID, or its fs LABEL.

    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmiDOHoACgkQseqq9sKV ZxmyNQ/6Ax1FAbRwLc1UiULkM1HmLnd44vmbce4ctHOCcKN5W2YyDd2xHJIkTTG4 IdayksaiB6ixuG0SwSsJ299f7UmDVuyvdRltQrJwUEihfCkw1Hy5OBBZOOycxc/6 Ax0zf+ZUHTRpSqCXZtiAGgNHFgzBsHG2WYrsjPyb135QP3qRzxfQoS/FFvKnBYRK Ta5aB4QhUbQ8inoOV/AhSCuEgp/8kjzfq0NhqxmLvF4oc0IYvC1QAbaazCR3wJUK Gzb6XizgWiuiW2yw2PfBA8puaEdcW+1c8mYGOrWOWY+c1KJNu6DPGs7yFo2GG1T2 Fpdbpxaaglrq9MPkPywsSBls2Cnw95OAhqnp9yovLcVafmGxoXpgOE3Te7yDW+Ht 03pHVEV5qjO7GpmOByCpL0qO7re8ZJe3pef495ciEiP3AUpsxYP7tORVIiFGEUlE e4NsbuJJHif6obkpbihrOO05GcSp0ixAXvcx9iGfk0BNF5RA1gHOpIecvh8T1kQB 74Y6hI5dch0NhSXkdeFAOv8KCXDuEO45H+KDp1wztTmqR9Bj5PnJXVfajmi9cLyb Mu3/kX7nzYtW7+8/7O3kW1ciNabHV2vIBQjgQ0pi2/ronuNYaL5dUO/R97pSknio Jw9Jh5RRtkzTTmKQYAB9xXbYzCykTHlQ38QB7DLlTdvtkAPKK3c=
    =bo4q
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Fri Jul 25 09:15:28 2025
    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

    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmiDPSAACgkQseqq9sKV ZxnZ+Q//Q2LufxJ5wAR5tio75MUA6gj75n/qTvbcSrRUv3s/sK15AElwUx6Ow5fq f4iBmKj7vqbH+87UQY0hvr84wvBJ0kfFK2A0ofV6gYYLzVQx0bYOnlMeDdix6GrR 7nSP7pn47RfWSBFkMqpZ3mxgvWixY57nEiMAtUpXyBdxq5N9sk/Skxenq8zTkHZp gYlq8mT0df5xIjP31lXUDHzs8hp6871FPbQmygXTfTj7iRFQGZ3MAw/w5CzbnYAh GFvd5Cd4oNnf65E1txvalSCTjWT36em3wel7aEvt10T1fCZ6Dzkpm8p6Z5+0RNte iq0jy8IM2FQ4lNmbYt6jRZ0tpygr4FyrDYSf3RoZsO2/Mwm7TzAA2akyUaOfuYry n3gzt6W8DcKFZMrli3ahkpjKVpiuW/0dOU8P6zu+eSK7Gp12yPRI79YdNVIL1f5z Mj6lydP7suN4z6ga1KFZq5H2L1HuxEgDd/ABhcTVoFGq9ahjVIXL6i9KdIb8zUZL rX6XEHgk9t8iAWofYXH19yJKI7Xcqt7ceb2DcPDYqu7QwHLo0bD/ak55BesTtaPo oeMWczuavHxZXw520UA3wbeYysB604Y7KJUX2GqZcfLz10/uKUaMVwGDsUuI9un2 KMHtpXBbmR/aeAzTeBzOZT1O7BXIcemlBZPanPZJtp230yRRrlE=
    =sK4p
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Dennis Clarke@21:1/5 to Javier Martinez on Fri Jul 25 16:50:01 2025
    On 7/25/25 08:35, Javier Martinez wrote:
    El 25/7/25 a las 9:38, Michael escribió:
    On Thursday, 24 July 2025 20:52:54 British Summer Time Dennis Clarke
    wrote:
    On 7/24/25 13:35, Michael wrote:

    I tried to boot with the GRUB built within the chroot stage3. I was very >>> careful to mount the correct FAT32 dos partition. The one on the board
    which appears as /dev/mmcblk0p1. However the board would not boot. It
    had some strange message and I did not record it.

    I guess I need to try that again.

    If it is not too cryptic it will at least give you a hint as to what is
    missing in your system or its configuration.


    <snip>

    Some day in the next years I will try it again, now, I'm tired.


    I am very thankful that there is someone that really understands how
    messy these sort of computer product are. They are a disaster to try
    to work with. What I have truely lost is time. Piles of it. I am tired.

    This morning, with coffee in hand and a stern glare at that damned
    horrific SiFive RISC-V P550 board ... I give up.

    It is an appliance. Not ever to be used for anything other than the very
    very few things that it can do. slowly. It ships with Ubuntu and perhaps something called Yocto.


    * * * I G I V E U P * * * *


    My time in life is far too valuable to waste on this trash. I will
    flash in the shipped Ubuntu and curse at it. Hate it. At the very
    least it will run something however Ubuntu is a pale shade away from
    Microsoft Windows 11 in my mind. Thus I despise it. I will not give
    another spilled coffee to this matter.

    I thank you and this mail list for the help that almost worked.


    --
    --
    Dennis Clarke
    RISC-V/SPARC/PPC/ARM/CISC
    UNIX and Linux spoken

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael@21:1/5 to All on Fri Jul 25 22:24:06 2025
    On Friday, 25 July 2025 18:02:59 British Summer Time Javier Martinez wrote:
    Also, you didn't thought one posibility, one kernel option that should
    be included in kernel monolitic and not included (as for example sata support, nvme etc) so I think your next pass shoulb be from ubuntu exec hwinfo command, and in the chroot, in /usr/src/linux do make menuconfig
    and switch as Y all drivers that hwinfo report. Compile kernel with make (pass it to /boot) and try

    Also, reaching out to who-ever in the ubuntu-land developed the working image to get some guidance may prove illuminating. This is more of a a learning- how-to-DIY exercise, or at least it would be for me.
    -----BEGIN PGP SIGNATURE-----

    iQIzBAABCAAdFiEEXqhvaVh2ERicA8Ceseqq9sKVZxkFAmiD9fYACgkQseqq9sKV Zxnv+Q//Rt15uo7A1ACCAJgtEsHtYzcoe97TSh6XUDjzkWsZXkkb7J2tsMgzipD+ s6B1lmKdKQK7OhfiI5INQD//fEGmhRoEhDu3zgubDsEH/F5qFETAwdJjsM1HoQNZ L6gvGoiXc2mXyrxBMpARafuQQMeOew6zi0m351MoMGwju0uI6ecx8HxTK2F3GE3c 8GLUSv95PS68pT30jR8arfqc7VSXkBpo0VIoXZ+f2kbV+doWzsmafWfp4whFsP8x L9qYBzFVpRIcN5etl2tZU945fWTo2fnDDwc5ArsCyBbUsxmQGmJz4YN5XMZRSgBo xqOJv83dr5PgOmGbHgxnWF7agAO3C515rapiGOWwczGptzs9A5OAQSU4E6NYddVm oXFBK4Qtdoqt5UEyQUokMOUG5rQJB8PuZM7iAoCuR4mtO1QuY17dW36qI/aADdn3 2CQTZneuO07j0iYGMDw3luKYcYjMBI5gMFELVX2nAHCqXMC1V6HZKv2L8yLLVbVt XyYV9l9dEdN/MdJc7rm1YGBhplcYFXZWxc/pALz52og79rMIkDifHSbh995f6GLN JUu8YfB7etOAdqZB2mAN7sD+y7ol1FPSvmzCbQrn+8955+UwTC0wlmINPcuTzVpe Brp39nC0KdPSQFzlW2IrD+OxnRT3NFHDJQoH0Gk1PTEnD7RApVk=
    =Cgu5
    -----END PGP SIGNATURE-----

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)