How to boot from microSD card image, not from the onboard flash?

444 views
Skip to first unread message

Tim M

unread,
Aug 6, 2017, 11:16:44 AM8/6/17
to BeagleBoard

I have a new BBB (Beaglebone Black, rev C). I just installed Robert Nelsons's latest Ubuntu image on a microSD card (https://rcn-ee.com/rootfs/2017-07-14/microsd/bone-ubuntu-16.04.2-console-armhf-2017-07-14-2gb.img.xz).

The onboard eMMC has the default Debian that came with the BBB. I don't really care what's installed in the onboard flash. I want to boot from the microSD card image, not from the onboard flash.

What's the best way to make my Beaglebone boot from the microSD card WITHOUT having to push the BBB's boot button during power-on?

Thanks,
Tim M

Greg

unread,
Aug 6, 2017, 12:10:32 PM8/6/17
to BeagleBoard
I think you are probably reading some outdated information on the web, and there is plenty of that!

The default mode of the images should be to boot from microSD.  This is controlled by commenting/uncommenting a line in the file uEnv.txt:


"To turn these images into eMMC flasher images, edit the /boot/uEnv.txt file on the Linux partition on the microSD card and remove the '#' on the line with 'cmdline=init=/opt/scripts/tools/eMMC/init-eMMC-flasher-v3.sh'. Enabling this will cause booting the microSD card to flash the eMMC. Images are no longer provided here for this to avoid people accidentally overwriting their eMMC flash."

Look at the very last line in the file

/boot/uEnv.txt

I have a Ubuntu desktop, and I can mount the image file and modify the file, then flash to the microSD.
Typically I develop something booting from the microSD, and later uncomment the line in uEnv.txt and flash to eMMC when whatever I am developing is ready to be permanent.
One word of advice, don't buy cheap microSDs.  Get the more robust devices designed for heavy duty usage.

Regards,
Greg


Tim M

unread,
Aug 6, 2017, 1:19:29 PM8/6/17
to BeagleBoard
Greg,

I downloaded this Ubuntu image (not a Debian image) and installed it on my microSD:

Are you saying that if I uncomment that line in /boot/uEnv.txt and reboot, the image I just copied to the microSD will be copied to eMMC?
I assume that after flashing the eMMC, I must comment that line again to avoid flashing the eMMC on every boot.
Is it necessary to have the same image in both eMMC and microSD to support automatic booting from microSD?
I assume I must flash the 2GB image to eMMC, before I resize the microSD partition to 8GB (the 8GB image won't fit in eMMC).

My goal is to boot from an 8GB microSD everytime, not eMMC. I really don't care what's in eMMC, I want to reliably boot from microSD.

To confuse matters further, I noticed that there is also a "flasher" image available:

What's the difference between the "microSD" and "flasher" images?

This is confusing.

Thanks,
Tim

Robert Nelson

unread,
Aug 6, 2017, 1:33:34 PM8/6/17
to Beagle Board
On Sun, Aug 6, 2017 at 12:19 PM, Tim M <timlori...@hotmail.com> wrote:
> Greg,
>
> I downloaded this Ubuntu image (not a Debian image) and installed it on my
> microSD:
>>
>>
>> https://rcn-ee.com/rootfs/2017-07-14/microsd/bone-ubuntu-16.04.2-console-armhf-2017-07-14-2gb.img.xz
>
>
> Are you saying that if I uncomment that line in /boot/uEnv.txt and reboot,
> the image I just copied to the microSD will be copied to eMMC?
> I assume that after flashing the eMMC, I must comment that line again to
> avoid flashing the eMMC on every boot.
> Is it necessary to have the same image in both eMMC and microSD to support
> automatic booting from microSD?
> I assume I must flash the 2GB image to eMMC, before I resize the microSD
> partition to 8GB (the 8GB image won't fit in eMMC).
>
> My goal is to boot from an 8GB microSD everytime, not eMMC. I really don't
> care what's in eMMC, I want to reliably boot from microSD.

so just dd /dev/zero into the eMMC..

>
> To confuse matters further, I noticed that there is also a "flasher" image
> available:
>>
>>
>> https://rcn-ee.com/rootfs/2017-07-14/flasher/BBB-eMMC-flasher-ubuntu-16.04.2-console-armhf-2017-07-14-2gb.img.xz
>
>
> What's the difference between the "microSD" and "flasher" images?

Those are explained here:

http://elinux.org/BeagleBoardUbuntu

Regards,

--
Robert Nelson
https://rcn-ee.com/

Greg

unread,
Aug 6, 2017, 4:56:18 PM8/6/17
to BeagleBoard
I'm curious, why the difference versus Debian?

I looked at the Ubuntu uEnv.txt and it has the flasher line commented just like Debian.
I made a bad assumption that this functionality was the same in both distros.
Reply all
Reply to author
Forward
0 new messages