BBB USB Hard drive boot - help

Welcome,

As for the beggining i would like to say tha im new to BeagleBoard enviroment , so please be patient.
I`m really curious if it is possible to use external USB hard drive (with own power supply) to use as main drive after boot sequence on BeagleBoard Black rev c.
I tried to follow up those instructions :
https://lumpynose.wordpress.com/2014/02/10/beaglebone-black-usb-hard-drive-boot-setup/
and
http://blog.ippe.biz/2013/11/running-ubuntu-off-usb-hard-drive-on.html

but they seem to be a little bit outdated sadly …

For now i have used following image flashed into eMMC :
https://rcn-ee.com/rootfs/2015-08-17/flasher/BBB-eMMC-flasher-debian-8.1-console-armhf-2015-08-17-2gb.img.xz

Any help with that matter would be much appreciated.

What’s the problem to mount a hdd after Linux booted?

The concepts are pretty much the same, except now days you’d probably use bootz instead of bootm. So the mkimage step wouldn’t be needed.

http://www.embeddedhobbyist.com/2013/07/beaglebone-black-usb-boot/

Thanks for the guide William, i tried it out but encountered some problems with it …
I have connected USB drive to the BBB and booted it normally , after that i stared using commands you indicated for formating the hard drive :
“sudo dd if=/dev/zero of=/dev/sda bs=1024 count=1024”

“sudo fdisk /dev/sda” then “n p 1 default default , t 83 p w”

“sudo parted --script /dev/sda set 1 boot on sudo mkfs.ext4 /dev/sda1 -L rootfs”

But i`m receiving “invalid option – ‘L’” …
Note that i have changed ‘sdc’ to ‘sda’ , beacuse this is how it is visible on BBB.

And in uEnv.txt (that is located /boot/uEnv.txt) file i need to add following lines :

"

uenvcmd=usb start;
bootpart=0:1
bootdir=/boot
loaduimage=load usb ${bootpart} 0x80200000 /boot/uImage
loadfdt=load usb ${bootpart} 0x815f0000 /boot/am335x-boneblack.dtb
mmcroot=/dev/sda1 ro rootwait
mmcboot=echo Booting from USB …; run mmcargs; bootz 0x80200000 – 0x815f0000
"
It`s just the same as changes you indicated on blog , but changed “bootm” to “bootz”

loaduimage=load usb ${bootpart} 0x80200000 /boot/uImage

This above is wrong. First you need to understand what a linux mage is.

i386

william@debian-can:~/can-dev/ipc-server$ ls /boot/
config-3.2.0-4-486 initrd.img-3.2.0-4-486 vmlinuz-3.2.0-4-486
grub System.map-3.2.0-4-486

The above is for an i386 / x86 PC

No idea what image you have on your BBB, but on two of mine . . .

debian@beaglebone:~$ ls /boot/uboot/
App Docs ID.txt MLO scripts u-boot.img zImage
autorun.inf Drivers initrd.img README.htm SOC.sh uEnv.txt
debug dtbs LICENSE.txt README.md START.htm uInitrd

william@xanbustester:~$ ls /boot/uboot/
MLO config-4.2.0-rc4-bone2 u-boot.img uEnv.txt.bak zImage
System.map-4.2.0-rc4-bone2 dtbs uEnv.txt v_mlinuz-4.2.0-rc4-bone2_

Anyway, starting to see my point ? You need to know what a kernel image is, and how to spot it. Then that is what loadimage= needs to point to.

sorry for such late response but i was quite consumed with getting mono winforms running on BBB …
Thanks for the tips , i learned some new things thanks to them , but the resolution to HDD was pretty easy , all i had to do was add in my “/uEnv.txt” file following arguments :

uenvcmd=**usb start;echo Booting from USB …;**run loadall; run mmcargs; echo debug: [${bootargs}] … ; echo debug: [bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}] … ; bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr};
echo command is not needed but wanted it to be in place for debuging measures :slight_smile:

Of course before this i had to format hard drive correctly and change fstab on it, but it`s described in your guide pretty nicely :slight_smile:
Thanks again for help !