jsciamms
Posts: 20
Joined: Wed Jul 01, 2020 2:11 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Thu Jul 09, 2020 5:54 pm

It sounds like your issue is the decompression of the kernel. From what I understand, getting stuck at the rainbow screen is what happens when the kernel fails to load.

My assumption is that zcat is giving you a error either because the wrong file is being sent in to the command or the kernel image your using, vmlinuz, is corrupt.

Did you download the most recent Ubuntu image for the pi4 from their website?

You can also try decompressing the kernel using another method. There are several methods listed in the previous posts.

Give that a shot, and let us know what happens. I went through the directions again, step by step, and had no issue.

jsciamms
Posts: 20
Joined: Wed Jul 01, 2020 2:11 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Thu Jul 09, 2020 6:19 pm

I have also updated the steps to include downloading the correct files for the RPI4 firmware.

NicknDi
Posts: 4
Joined: Tue Jul 07, 2020 9:47 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Thu Jul 09, 2020 9:07 pm

Thanks for the feedback. I downloaded the image from the Ubuntu website earlier today, but it was the 32bit version; should I have used the 64bit? (I was following recommendation from another site - possibly the official RPi site.) I did a verification after downloading.

I'll try again tomorrow, with a different approach to decompressing vmlinuz. I'll post as to how I get on.

kazin08
Posts: 14
Joined: Thu Feb 14, 2019 10:08 pm

Re: RPI4 Direct USB Boot Ubuntu 20.04

Fri Jul 10, 2020 1:24 am

Hi,

can someone share the version of the kernel? i'm having diferent versions of the kernel if i boot from SD and switch to HDD and if i boot from HDD.

Another question, did someone has this working in an old HDD 3.5? i was trying whit mi HDD but after reboot it never boot again but if o use one HDD 2.5 i can reboot without any problem.

regards

User avatar
ranrinc
Posts: 12
Joined: Tue Feb 25, 2020 7:23 am
Location: Jakarta Indonesia
Contact: Website

Re: RPI4 Direct USB Boot Ubuntu 20.04

Fri Jul 10, 2020 4:51 am

kazin08 wrote:
Fri Jul 10, 2020 1:24 am
Hi,

can someone share the version of the kernel? i'm having diferent versions of the kernel if i boot from SD and switch to HDD and if i boot from HDD.

Another question, did someone has this working in an old HDD 3.5? i was trying whit mi HDD but after reboot it never boot again but if o use one HDD 2.5 i can reboot without any problem.

regards
I believe you need to be sure that the enclosure used for that HDD is being recognize by Ubuntu. Else it will surely fail to boot

jsciamms
Posts: 20
Joined: Wed Jul 01, 2020 2:11 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Fri Jul 10, 2020 5:07 am

NicknDi wrote:
Thu Jul 09, 2020 9:07 pm
Thanks for the feedback. I downloaded the image from the Ubuntu website earlier today, but it was the 32bit version; should I have used the 64bit? (I was following recommendation from another site - possibly the official RPi site.) I did a verification after downloading.

I'll try again tomorrow, with a different approach to decompressing vmlinuz. I'll post as to how I get on.
Only the 64 but kernel needs decompressing. 32 bit kernel will load without that step. Try it tomorrow without doing the decompression, and let us know what happens. If it loads without issue, I’ll add a note to the original instructions.

NicknDi
Posts: 4
Joined: Tue Jul 07, 2020 9:47 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Fri Jul 10, 2020 10:27 am

jsciamms wrote:
Fri Jul 10, 2020 5:07 am
Only the 64 but kernel needs decompressing. 32 bit kernel will load without that step. Try it tomorrow without doing the decompression, and let us know what happens. If it loads without issue, I’ll add a note to the original instructions.
Success!

I figured that yesterday I had in any case tried without doing the decompression, as after getting the error message I checked the vmlinuz file and saw it was not in a compressed format, so I ignored the error and carried on with the remaining steps.

This morning I downloaded the 64bit version of Ubuntu 20.04, followed all your steps and it went smoothly. Hooray, and thank you!

As an afterthought, I'm wondering if the .dat and .elf files could be the culprit? Way beyond my level of knowledge, but could they be 32 or 64 bit specific? If so, then the ones downloadable via your link are clearly 64bit and perhaps worth adding a note at the start of your post advising folks to download the 64bit version of Ubuntu?

jsciamms
Posts: 20
Joined: Wed Jul 01, 2020 2:11 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Fri Jul 10, 2020 1:08 pm

The elf and dat files are the firmware for the Raspberry Pi hardware. I know that they work with the raspberry pi OS (previously raspbian), which is 32bit by default, so I’m not sure that they are the culprit, but there is clearly something up with booting the 32bit version of Ubuntu.

With the raspberry pi 4, especially the versions with larger ram, there is really no reason to boot the 32bit OS’s. 64bit will perform better and has built in support for the larger ram sizes (4GB and 8GB) without needing PAE (Physical Address Extension), as 32bit can only support a max of 4GB, but usually less in the real world because of other things also need register addresses.

If I have time later this evening, I might look into it and just see if I can get it to boot, but really the 64bit version is the way to go for the RPI4.

jrullan
Posts: 5
Joined: Sat Oct 31, 2015 10:50 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Sat Jul 11, 2020 12:15 am

Hello everyone,

I tried this process today after using the instructions here https://www.raspberrypi.org/documentati ... torageboot to enable USB boot on the pi4. I stumbled upon an error while booting without the sdcard:

Code: Select all

start4.elf is not compatible usb-msd requires newer software
After several hours looking around I went back to the rpi-eeprom-update instructions and noticed that currently their instructions point to a stable eeprom of 2020-06-15.
sudo rpi-eeprom-update -d -f /lib/firmware/raspberrypi/bootloader/stable/pieeprom-2020-06-15.bin
So I went back to github and switched to the branch previous to the current one and then copied the *.elf and *.dat from that branch to the boot partition and it booted from the SSD without the sdcard inserted.

jsciamms
Posts: 20
Joined: Wed Jul 01, 2020 2:11 am

Re: RPI4 Direct USB Boot Ubuntu 20.04

Sat Jul 11, 2020 4:43 pm

Updated in the original post. I incorrectly assumed that this would have already been done if you were trying to boot Ubuntu from USB, however, it is good information to add to the instructions.

basicsofcomputing
Posts: 1
Joined: Sun Jul 12, 2020 3:55 pm

Re: RPI4 Direct USB Boot Ubuntu 20.04

Sun Jul 12, 2020 4:01 pm

Has anyone had serious stability issues after this?

I updated the eeprom to the stable version. Then flashed ubuntu server 20.04 LTS with updated elf and dat files and the decompressed kernel.

Yesterday, I was having immediate crash upon connecting any other USB 3 hard disk in addition to the SSD I was booting from. (Yes, the USB 3 HDD was powered externally and was working perfectly fine for weeks before the bootloader update and Ubuntu was booted from SD card)

Today, Ubuntu will just not stay on for more than 20 minutes. It will just randomly crash with the last line in the kernel log being - brcmfmac: brcmf_cfg80211_set_power_mgmt: power save enabled

The crash happens with or without anything connected to the rpi, whether ubuntu is booted from SD card or SSD.

I am wondering if the bootloader is incompatible with ubuntu because as of now, the 64-bit version of RaspbianOS stays on without a major issue.

Return to “Ubuntu”