Outline

The general procedure to install Ubuntu (or Ubuntu flavour, Kubuntu, Lubuntu, Xubuntu, ...) from a USB flash drive is:

See also: Installation/FromUSBStickQuick for beginners starting from Windows.

Introduction

Ubuntu can be installed from a USB flash drive. This may be necessary for most new portable computers without DVD drives and is handy for others because a USB flash drive is so convenient. Also, you can configure Ubuntu on the USB flash drive to save changes you make, unlike a read-only CD/DVD disk.

Booting from a USB flash drive created with usb-creator alias Startup Disk Creator and mkusb will behave just as if you had booted from the install CD. It will show the language selection and then the install menu, from which you can install Ubuntu onto the computer's hard drive or launch the LiveCD environment. Other utilities, e.g. UNetbootin, may create slightly different boot drives or if on UEFI might not work at all with Debian iso files due to a bug

Note: This article uses the term "USB flash drive" alongside USB stick, USB drive, USB device, USB pendrive and thumb drive.

Prerequisites

To create a USB installation device, you will need:

Dummy headlines

After a major remake of this help page the following headlines are kept here because they may be linked to from other web sites. Several other headlines further down in the page are also kept for this reason.

Notes about speed

Notes about size

Notes about bootability

The flash hardware

There is a detailed description at the sub-page /pre

Creating a bootable Ubuntu USB flash drive from Windows

There are various methods available for Windows to create a bootable Ubuntu USB flash drive.

NEVER try to use one of your hard disk drives or partitions in this process unless you really know what you are doing, as data will get erased.

Rufus

Rufus is the tool in Windows that is recommended officially by Ubuntu. A tutorial is available from here.

Download Rufus.

balenaEtcher

Download balenaEtcher

Pendrivelinux's Universal USB Installer

Download Universal USB Installer

UNetbootin

Download UNetbootin

Win32 Disk Imager

Download Win32 Disk Imager

There is a detailed description at /fromWindows including Rufus, balena Etcher, Universal USB Installer, Unetbootin and Win32 Disk Imager.

Creating a bootable Ubuntu USB flash drive from Ubuntu

Install and run Startup Disk Creator alias usb-creator

You can find usb-creator-gtk by typing "Startup Disk Creator" (Ubuntu Desktop) or usb-creator-kde in K-Menu-->Applications-->System-->Startup Disk Creator (Kubuntu). If it is not there, then you can install it using the Ubuntu Software Center.

The Startup Disk Creator clones the iso file, which means that you need neither erase nor format the target drive. It will be completely overwritten anyway by the cloning process. The Startup Disk Creator looks like this in Ubuntu 18.04 LTS:

Screenshots: Startup Disk Creator - to SSD or pendrive

Notes

UNetbootin

mkusb - dd image of iso file to USB device safely

There is a detailed description at /fromUbuntu including the Startup Disk Creator, UNetbootin and mkusb.

Creating a bootable Ubuntu USB flash drive from Mac OSX

See How to install Ubuntu on MacBook using USB flash drive and this Ubuntu Forum thread by Quackers

UEFI

There is a good wiki page about booting with UEFI, and a good tutorial thread, UEFI Installing - Tips.

Test if running in UEFI mode

You may want to test if your Ubuntu flavour is running in [U]EFI mode. An installed system and a live system too is using the directory /sys/firmware/efi, so you can run the following command line,

test -d /sys/firmware/efi && echo efi || echo bios

The following command line is more robust and also easier to understand, so you may prefer it (if you copy & paste and are not bothered by typing a long command line),

if test -d /sys/firmware/efi; then echo efi; else echo bios; fi

Boot and install

Stable portable systems - good for USB sticks

Creating an EFI-only image

Ubuntu single boot in UEFI mode

There are more details at the sub-page /uefi

Alternative methods

'Do it yourself'

When the boot structure is modified in Ubuntu or the booting software, there can be problems until the extracting tools are modified to manage the modification. It is worthwhile to find a method that is as simple as possible and to learn how to use it in order to manage the extraction also when the boot structure is modified.

See this link: Installation/iso2usb#Do_it_yourself

Portable installed system booting from UEFI and BIOS

Multiboot pendrives

Booting ISO files on internal drive

Booting USB drives with grub2 and iso files 'grub-n-iso'

There are more details at the sub-page /alt

Booting the Computer from USB

Remove all unneeded USB items, but keep the network cable attached.

Boot menu

Instead of editing BIOS settings, you can choose a boot device from the boot menu. Press the function key to enter the boot menu when your computer is booting. Typically, the boot screen displays which key you need to press. It maybe one of F12, F10, F9.

Edit the BIOS settings

Insert the bootable USB flash drive that you just created in your target computer and restart it. Most newer computers can boot from a USB flash drive. If your computer does not automatically do so, you might need to edit the BIOS settings.

Restart your computer, and watch for a message telling you which key, hotkey to press to enter the BIOS setup.

Press this hotkey continuously or tap repeatedly (different between computers) while your computer is booting to edit your BIOS settings. (On HP Mini Netbooks, the correct key is usually F9.)

Select 'hard disk/USB-HDD0'

Note: with some motherboards you have to select 'hard disk/USB-HDD0' to choose the USB flash disk. It may work like this because the system sees the USB drive 'a mass storage device' as a hard disk drive, and it should be at the top of the boot order list.

So you need to edit the Boot Order. Depending on your computer, and how your USB key was formatted, you should see an entry for "removable drive" or "USB media". Move this to the top of the list to make the computer attempt to boot from the USB device before booting from the hard disk.

Chainloading

PLoP Boot Manager

Flow chart for trouble-shooting

There are more details at the sub-page /bootUSB

Known Issues

Postrequisites - restore the USB stick

'Postrequisites' - after installation: how to restore the USB stick to a standard storage drive. The standard is an MSDOS partition table (MBR) and a partition with the FAT32 file system.

gparted

Disks

mkusb

There is a detailed description at the sub-page /post


See also


CategoryLive CategoryInstallation CategoryInstallation CategoryInstallation

Installation/FromUSBStick (last edited 2024-12-23 16:54:29 by nio-wiklund)