Download a bootable ISO or IMG directly to a USB stick or SD card
February 10, 2016

In this short tutorial, I will show you how to download a bootable ISO or IMG directly to a USB stick or SD card. This is useful in many situations such as creating a live usb on a computer without alot of disk space, or just creating a linux installation disk. The instructions are below:

  1. Find the URL of the ISO or IMG to download
  2. Open a terminal
  3. Type the following command: df -H You will get the following output or something similar:
Filesystem      Size  Used Avail Use% Mounted on
udev            2.0G     0  2.0G   0% /dev
tmpfs           388M  6.7M  382M   2% /run
/dev/sda1       311G  4.1G  292G   2% /
tmpfs           2.0G  250k  2.0G   1% /dev/shm
tmpfs           5.3M  4.1k  5.3M   1% /run/lock
tmpfs           2.0G     0  2.0G   0% /sys/fs/cgroup
tmpfs           388M   13k  388M   1% /run/user/120
tmpfs           388M   25k  388M   1% /run/user/1000
/dev/sdb1        11G  4.0G  6.8G  37% /media/ubuntu/PATRICK
/dev/sdb2       5.0G  1.2G  3.8G  24% /media/ubuntu/Stuff
  1. Find your USB drive in the list. In my case, my USB has two partitions: PATRICK and Stuff. Find it on the list, and look for the text starting with /dev/. Ignore the number at the end. Remember the path. In my case it is /dev/sdb
  2. Type the following command: curl URL_OF_ISO_OR_IMG |sudo dd of=USB_PATH

    • Replace URL_OF_ISO_OR_IMG with the URL you found in step 1.
    • Replace USB_PATH with the path you found in step 4.
    • Warning: This will wipe the drive you say for the USB path. Be careful.
    • The final command will look something like: curl http://releases.ubuntu.com/15.10/ubuntu-15.10-desktop-amd64.iso |sudo dd of=/dev/sdb
  3. Wait for the command to finish
  4. You are done. You can now boot to the USB drive if you wish.
Patrick G
Patrick G
I like to write code. I love open source software. I like to self-host stuff.