Other OS

Mounting /root from USB device at boot time

30 19738
eckarth  
I wanted to mount /root from an USB device instead of from the SD card (/dev/mmcblk0p2). On a rasPi I can do that by editing /boot/cmdline.txt. I see that on a BananaPi uEnv.txt might have that role instead. But if I edit the file such that root=/dev/sda1, the system does not boot up.

Any suggestions?

TIA
I test mount the root on sata, it works. What is the boot log?

jib  
Post Last Edited by jib at 2014-7-9 12:37

I had the exact same problem, the boot sequence is stuck on "waiting for root device /dev/sda1".

When I unplug/replug the usb stick, I can see the device being detected but then nothing more happens.

I then copied the content of my USB stick (raspbian "/" partition previously running on a Raspberry Pi) to the SD card partition and it boot properly but again, no USB device is being created.
It seems like udev is not creating the device even if the device is being detected by the OS.
This issue doesn't happen when I boot from the Banana Pi Raspbian version.

ddurdle  
Hi folks.  I've been using raspbian on Raspberry Pi model B with a powered USB dock for a year.

My Banana Pi arrived this week.  I setup the Raspbian 3 image on SD card.  I proceeded to build a SATA USB hard drive like I did for my Raspberry Pi following the changes here: http://www.raspberrypi.org/forums/viewtopic.php?p=351659#p351659

I've run into the same problem discussed in this thread.  When I set up to boot off the SD card to then boot root off the USB, I get stuck waiting for root device.  It gives a USB error -110 several times until finally it ends up booting up SD card.  Once the system is booted, the USB partitions are mounted, but the root is off the SD card.

There must be something wrong with the startup.  Right after it says populating /dev, you get these USB -110 errors .  I've tried two different hard drives (2.5") and two different USB SATA enclosures.  All I can mount and view on the Banana Pi when booted off SD, but won't boot off / on USB.  The Raspberry Pi boots off the hard drive applying the same workaround.

I don't have a proper SATA cable for the Banana Pi, so I'm not able to test using SATA.

ddurdle  
Waiting for /dev to be fully populated....

The error is Device Descriptor read/64, error -100

(error -110 repeats 5 times) before it moves onto booting off SD

eckarth  
Post Last Edited by eckarth at 2014-7-9 13:57

Post Last Edited by eckarth at 2014-7-9 13:05

I am using a USB thumb.

What boot log do you mean? Hopefully not /var/log/dmesg, as that is never written as it resides on /root.

Should say that eEnv.txt specifies rootwait. Hence, I think it waits forever.

PS: The bananaPi is presently without screen, i.e. I can not read that either.

ddurdle  
Reply 6# eckarth


   I believe he means there is a hardcoded root value in uEnv.txt, which I notice as well.  it is set to the second partition on the SD card.  If you change this to /dev/sda1 for instance, the system won't boot at all.

eckarth  
Reply 7# ddurdle

That depends. My USB thumb has only one partition which is mounted as /dev/sda1 as there is no other (competing) USB device mounted. That is where I have the UXIX system to mount on /root.

http://forum.lemaker.org/viewthr ... &extra=page%3D1
Here bpi-roe boot root file system from SSD.

jib  
Reply 9# tony_zhang


   It works because he is using SATA. It doesn't boot using USB (at least for me and some others).

You have to log in before you can reply Login | Sign Up

Points Rules