Ubuntu rootfs on USB HDD

To this you'll need:

Running the guide will erase the contents of your MicroSD/USB Disk. Its highly recommended to double check before running any of the commands it may even break your OS Install

Replaced /dev/sdX with the microsd/usb disk nodes! Make sure of what you are choosing here!

Replace ubuntu-14.04.1lts-lubuntu-odroid-c1-20141211.img.xz with the name of a new image if it exists!

1. Become root!

sudo -s

2. Clean up the MicroSD

dd if=/dev/zero of=/dev/sdX bs=1M count=10

3. Write the base to the microsd card.

xzcat ubuntu-14.04.1lts-lubuntu-odroid-c1-20141211.img.xz | dd of=/dev/sdX bs=1M count=150

4. Remove a useless partition from MicroSD

parted /dev/sdX rm 2

5. Sync to write any left data

sync

6. Remove the MicroSD and connect it to the board. Don't power it up yet! Also, connect your USB HDD or USB Flash Drive to your PC.

7. Clean up the USB DISK

dd if=/dev/zero of=/dev/sdX bs=1M count=10

8. Write the image to the USB DISK

xzcat ubuntu-14.04.1lts-lubuntu-odroid-c1-20141211.img.xz | dd of=/dev/sdX bs=1M

9. Remove the useless partition from the USB DISK

parted /dev/sdX rm 1

Be careful, the command below must be run exactly as its posted. Just replace the /dev/sdX for your device!

10. Resize the partition the USB DISK

fdisk /dev/sdX <<EOF
d
2
n
p
2
266240

w
EOF

11. Clean & Resize the USB DISK

e2fsck -y -f /dev/sdX2
resize2fs /dev/sdX2

12. Sync up to make sure everything is written

sync

13. Connected everything to the board and power it up! It should work.

If you want to discuss this guide jump into our Forums Make sure to post logs and use a very rich amount of details.

Useful Tips by johnbeetem from the ODROID Forum