On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke wrote:
Dear gentoo folks :[snip ...]
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 :
[ 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.
On 2025-07-24, Michael wrote:wrote:
On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke
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)?
On Thursday, 24 July 2025 16:46:10 British Summer Time Nuno Silva wrote:
On 2025-07-24, Michael wrote:wrote:
On Thursday, 24 July 2025 15:17:02 British Summer Time Dennis Clarke
Dear gentoo folks :
I am making very very slow progress with the SiFive P550 RISC-V
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.
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.
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
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.
On 7/24/25 17:24, Javier Martinez wrote:
Dennis
You have reached to the trully nightmare of embeeded devices. Howthe
hell can I boot this shoe box, I spent nearly 4 months in makerockpi
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
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.
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.
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 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 *
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.
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
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.
Some day in the next years I will try it again, now, I'm tired.
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
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 546 |
Nodes: | 16 (2 / 14) |
Uptime: | 146:31:22 |
Calls: | 10,383 |
Calls today: | 8 |
Files: | 14,054 |
D/L today: |
2 files (1,861K bytes) |
Messages: | 6,417,708 |