Make a bootable flash drive from an ISO image
We all know that installing an operating system from a USB drive is much faster than installing from DVD. In this article we will look at several ways to create a bootable USB drive.
Before describing how to create a bootable USB drive read the article How to correctly format the USB stick in Linux Mint. In some cases described below, it is desirable to have already formatted the USB flash drive in FAT32 format.
1. LinuxLive USB Creator (only for Windows users)
If you are a user of the Windows operating system and want to make a bootable USB flash drive with a Linux distribution – this program is for you.
It is very simple, select the USB flash drive, please specify the iso image will be copied, turn on the option to format the USB stick and click on the lightning.
You can download the program on the official developer’s website http://www.linuxliveusb.com/en/download.
Rufus is a utility that helps format and create bootable Flash/Pen/Key drives, memory cards, etc.
Rufus will be especially useful in cases where:
-you need to create a bootable USB disk from a bootable ISO image (Windows, Linux, UEFI, and others)
-need to work on systems that have no OS installed
-you need to flash a BIOS or other firmware from DOS
-you need to run a low-level utility
-Despite its small size, Rufus knows how to do everything!
3. UNetbootin (for Linux, Windows, Mac users)
A very common program. The principle of operation is the same as the previous program. Select the image, select the flash drive, and click OK. For details, see the screenshots below.
Installation latest version into Linux Mint 14/15/16/17/17.1:
4. LiveUSB MultiSystem (for Linux users) -To create a bootable USB flash drive with multiple operating systems (windows or linux) read article Create your LiveUSB MultiBoot very simple in Linux Mint.
5. Either – program to burn the iso image with the distro on a USB flash drive or micro SD card (Windows, MacOS and Linux) read article Either – program to record the iso image on a USB flash drive
6. YUMI – Multiboot USB Creator (for Linux, Windows users)
YUMI (Your Universal Multiboot Integrator), is the successor to our MultibootISOs. It can be used to create a Multiboot USB Flash Drive containing multiple operating systems, antivirus utilities, disc cloning, diagnostic tools, and more. Contrary to MultiBootISOs which used grub to boot ISO files directly from USB, YUMI uses syslinux to boot extracted distributions stored on the USB device, and reverts to using grub toBoot Multiple ISO files from USB, if necessary.
Important Note : YUMI was intended to be used to try to run various “LIVE Linux” Operating Systems from USB. Installing Linux from the YUMI created USB Drive to a Hard Drive is not officially supported. If the installer portion of any Live Linux distro does work, consider it a bonus.
Installation latest version into Linux Mint 14/15/16/17/17.1:
Download DEB package “YUMI for Ubuntu Linux” from website
7. USB image writer (for Linux users)
Linux Mint have default utility USB image writer. One time I used this program, but personally I have not always made a bootable USB flash drive.
Locate menu, the program will run. Select the image, select the USB drive and click Write.
Multiboot USB flash drive designed for loading and installing operating systems Windows/Linux and restoration-resuscitation tools directly from the USB drive.
9. WinUSB – Create Windows Usb stick
is a simple tool that allows you to create your own Windows installation on USB stick from an ISO image or DVD disk in Linux Mint.
10. Using the terminal (in my opinion the best 100% of the way)
As is known, the terminal is installed in any Linux distribution by default, so install additional software is not required.
The terminal command to write the iso image, the distribution is as follows:
Where instead of /home/USER/linuxmint.iso you need to specify the path to the iso file. sdb in the end, it’s a stick on which is written the way.
To determine your flash drive, run in terminal:
And if you stick decided differently, change in the command.
To be entered correctly in the command path to the file, open the folder with the file, open next to the terminal and drag the file into the terminal:
Now we are ready to start. I got the command:
The cursor of the terminal is blinking and it seems that nothing happens, but actually being recorded. Wait for the image capture and at the end you should see in the terminal like this:
The site has moved to a new engine, help me fix bugs, send me your notify by selecting that text and pressing Ctrl+Enter.
How to create a bootable Ubuntu USB flash drive from terminal?
Is there any way to create a bootable Ubuntu USB flash drive from the terminal without using any third-party applications like YUMI, Unetbootin, Startup Disk Creator, etc.
I tried to create a bootable Ubuntu flash drive with dd method,
It creates files on the USB disk, but when I try to boot the USB disk it shows an Operating System Not Found error.
8 Answers 8
where is a letter followed by a number, look it up by running lsblk .
It will look something like
I would dismount sdb1.
Then, next (this is a destructive command and wipes the entire USB drive with the contents of the iso, so be careful):
where input.iso is the input file, and /dev/sd is the USB device you’re writing to (run lsblk to see all drives to find out what is for your USB).
This method is fast and has never failed me.
EDIT: for those on a Mac ending up here, use lowercase for bs=4m :
EDIT: If USB drive does not boot (this happened to me), it is because the target is a particular partition on the drive instead of the drive. So the target needs to be /dev/sdc and not dev/sdc For me it was /dev/sdb .
You’re almost there with dd , but you’re missing a step.
where sdX is your usb device (this can be verified with lsblk ).
The sync bit is important as dd can return before the write operation finishes.
Creating a bootable Ubuntu USB flash drive from terminal
Place the ubuntu.iso file in any hard disk partition.
Then mount the ubuntu.iso file with the below commands in terminal:
Insert your USB flash drive. My drive is /dev/sdd . Here’s a screenshot:
Your drive may be automatically mounted inside /media/ . Let’s assume that it was mounted in /media/xxx/ .
Copy all files from /media/iso/ to your mounted USB flash drive by running the below command (make sure to include the dot):
Next, you need the ldlinux.sys file in your USB flash drive to make the USB bootable. My USB partition is /dev/sdd1 ; enter lsblk to see what’s yours. Run the below commands:
Navigate to the /media/xxx mount folder and rename the isolinux directory to syslinux . Then go into the renamed folder and rename the file isolinux.cfg to syslinux.cfg .
Reboot your PC and change the boot order in BIOS to allow booting from a USB drive. Now your Ubuntu USB flash drive will boot and you can install it.
This method will work for any Linux distribution, not only Ubuntu. You don’t need to install any third party software to make a Linux USB flash drive.
You have two choices.
If you desire a graphical interface, use usb-creator (it is in the ubuntu repos)
If you want a command line tool, use dd
Just be sure /dev/sdX is the flash drive you wish to use (it will destroy the data on the flash drive).
First, unmount the USB device and then use lsblk to verify the device.
Sometimes (usually older iso files) dd is not sufficient and the pendrive will not boot. In this case, you may need to install syslinux:
and then run the following commands:
You want to run that last command to /dev/sdX and not /dev/sdX1 .
Then, proceed with the following commands:
or, to see progress of image write:
or instead of dd , you can use cat instead:
Rememeber to issue sync command to flush write cache
If by «third-party» you mean «GUI», I suggest a lightweight script named bootiso after Avinash Raj answer, because dd does not always work. The big plus is it’s very secure (performs many security checks not to mess up with the system), easy to install and portable.
Also, bootiso will inspect the ISO file to choose from two modes: «image-copy» ( dd ) when the ISO file is hybrid (means: USB boot friendly). And «mount-rsync» mode when ISO file is non-hybrid, in which case a SYSLINUX bootloader will be automatically installed if supported [more details about automatic behavior].
How to use it
First option, just provide the ISO as first argument and you’ll be prompted to select a drive amongst a list extracted from lsblk :
Or provide explicitly the USB device:
Quick install
See it in action
Don’t use the path to bit.
- Use the cd command to get to the folder that contains the .iso file
- use the command dd if=FILE NAME HERE.iso of=/dev/sdX bs=1MB
Wait until the console output looks something like this:
Note: Make sure you write to the correct device a usb will not always be mounted at: dev/sdX where X can be any letter.
Title
How to create a bootable Ubuntu USB flash drive from terminal?
There are built-in text mode tools, that you can run from a text screen or a terminal window. dd or cp or cat can be used, but they are not safe because they do what you tell them to do without any question, and a minor typing error is enough to overwrite a drive with valuable data.
Fortunately there are also safer text mode tools, but you have to install them.
Install mkusb via its PPA: If you run standard Ubuntu live, you need an extra instruction to get the repository Universe. (Kubuntu, Lubuntu . Xubuntu have the repository Universe activated automatically.)
Installing this way will add not only mkusb but also some program packages that mkusb depends on.
If you want a small tool or if you don’t like PPAs or don’t want any extra program packages, you can use mkusb-min. This shellscript is very small compared to the other versions, yet it serves the purpose to wrap a safety belt around dd .
It should be rather easy to see what the shellscript is doing simply by reading it in a text editor.
Download mkusb-min from its Ubuntu help page. Run it locally or install it into a directory in PATH .
xorriso-dd-target is a new tool, intended to be uploaded to a Debian repository. The purpose is to make it very safe to create boot drives (USB pendrives or memory cards). A special feature is the plug-in method to identify the target device. The man page is available here. In January 2020 there is not yet any installer, but you can copy and paste from the links above and install the shellscript and man page manually.
Finally I want to mention bootiso which is described by its developer in another answer.
Question
Is there any way to create a bootable Ubuntu USB flash drive from the terminal without using any third-party applications like YUMI, Unetbootin, Startup Disk Creator, etc.
If we must look for text mode tools that are already installed in Ubuntu, I am afraid that there are no safe tools available. So in this case I can only suggest that you use dd or cp or cat according to many of the other answers here. But please check and double-check that you are really pointing to the intended target device before pressing the Enter key.
(By the way, the Ubuntu Startup Disk Creator belongs to Ubuntu (is not third party), but it needs a graphical desktop environment or at least a graphical window manager.)