of course you can boot from sdcard and use ssd for rootfs, but you cannot boot directly from sata. you need either sdcard or emmc to get into uboot
then you can change rootfs passed to linux kernel
just override root and change it to the ssd (/dev/sdxy)
if you want to have uEnv.txt/kernel on ssd too it is a bit more difficult as you need to adjust device and partition and make sure sata is correctly intialized…as your uEnv.txt then is already on sata you need to change uboots builtin environment (= change the file from my repo and recompile/reflash uboot)
“you can boot from sdcard and use ssd for rootfs, but you cannot boot directly from sata. you need either sdcard or emmc to get into uboot”
Ok great, this is what im trying at the moment.
“then you can change rootfs passed to linux kernel”
Ok but where i need to change this? Where is the file located that you attached? Is it somewhere on the Boot-Partition? Sorry, i was not able to find it.
your log says that my script detects SD boot so it will try to load from sdcard. if you remove sdcard it
should print emmc
ok i moved the Boot-Partition from SD to MMC, and removed the SD-Card.
It is not booting, without the SD, and there is no output on the UART.
Check out this post about fstab
i don’t really understand how “fstab” help me in this case. Should i mount the emmc here so that uEnv.txt will be found by uBoot on bootup?
basicly my debian images support emmc too with some adjustments like changing root in uEnv.txt and in fstab
I have Ubuntu 20.4.03 installed at the moment. I don’t really want to downgrade to an older version, and setup everything else from the beginning.
you have to put bootheaders, uboot and the boot-partition to emmc and there a uEnv.txt
is there any manual how to do this? I found this http://www.fw-web.de/dokuwiki/doku.php?id=en:bpi-r2:storage from you Frank. But i’m unsure what i need to install first (preloader?, uboot?)
And i’m also not sure if this manual for ubuntu 14.x is still up to date.
basicly you need only the steps to fill the boot0 partition with the emmc preloader, then flash my debian-image to emmc userpartition (/dev/mmcblkX), change uenv.txt (for uboot - root passed to linux kernel) and fstab (mount of rootfs)
I did the first 3 steps without any errors. In step 4 i moved the unzipped Image to the sd card and moved it via “dd” to the mmc. I just don’t know what to do here:
Where do i get the Zip-File and where should move it to? Or is it not necessary?
I skipped this point for now, and tried to boot the R2 without SD-Card. But uBoot is still not displayed. I also checked the bootswitch. But it the same result when its switched to SD or EMMC.
Is there anything i forgot?
this is dd’ing the image to user-partition, if you have the image already uncompressed, you can do
dd if=image | pv | dd of=.....
or if you don’t need status or have not installed pv
dd if=image of=device ...
maybe adding status=progress (newer dd imho have it) instead of noxfer
as i said, you should see at least bootrom (~10 lines of output before any other header is read)…for uboot you have to write the image. if you see bootrom but no further output maybe partition config is wrong or preloader on boot0 is missing
ok, i used your image (linked above) and put it on a sd-card. I changed uEnv.txt and fstab to my ssd with the ROOT-partition on it - and it works! yeah! Thanks for that!
Then i tried to move the image on the emmc (https://bananapi.gitbook.io/bpi-m3/zh/howtoburnlinuximagetoemmc) and removed the sd card. It does not boot anymore. As long as i press the power-button, the leds are on. When i release ti after 15seconds, all leds are off. No message on UART. Boot-switch does not change anything.
As i said above,you have to flash the image to emmc main partition…if you have uncompressed it before you need no (g)unzip,simply dd if=image of=targetdevice
early preloader does not allow larger uboot binary, i do not remember the error appearing there, but current uboot for r2 contains usb and sata and so it will be larger than on first days when i’ve wrote the manual
one last thing: when i booted from SD, i needed to press the power-on button for more than 10 seconds.
Now i just need to press it for 2-3 Seconds. Is there any reason why SD needs so long?
And is it possible to bridge the power on button? So that it will autostart like a raspberry pi? I read somewhere else, that this can cause other issues.
this is a hardware-limitation, that boards needs power for more than 10 seconds to keep on. you can bridge it or add additional power on otg port. but for first you need to make sure that you do not have mtk-pmic-keys active as they look if powerbutton is pressed and then trigger reboot/poweroff