Boot and run Ubuntu from the USB drive

The TipsMake article below will show you how to boot and run Ubuntu from a USB drive and other Linux distributions. You can automatically save changes and settings on the USB drive and restore each boot using the 2nd partition.

Boot and run Ubuntu from the USB drive Picture 1

This way you can run Ubuntu and its settings and files even on other computers. Continue reading the article below.

Boot and run Ubuntu from the USB drive Picture 2

Note: The instructions below do not require Ubuntu 8.10 because USB Ubuntu Creator is already integrated.

Boot and run Ubuntu from the USB drive

Request

Boot and run Ubuntu from the USB drive Picture 3

- USB 2.0 drive with minimum capacity of 1GB.

- Computer with CD drive (must be able to boot from USB drive. Devices with new motherboards will meet the requirement. BIOS update from good computer manufacturer).

- Ubuntu LiveCD (if your computer has Ubuntu installed, you do not need the Ubuntu LiveCD).

- Have knowledge of Terminal.

You can visit ubuntu.com to download the Ubuntu LiveCD. Download the Ubuntu Desktop LiveCD ISO file and burn it to CD using Nero or another program.

Change BIOS boot order

The next step to do now is to change the BIOS boot order. Turn on your computer, during the boot process press the button to access the BIOS Setup Utility. Depending on your computer, the keys may vary, but are usually F2 or Delete.

Navigate around the settings until you find the boot order setting. You can change the boot order to choose to boot from your device first.

Also on boot you will have the option to temporarily boot from the specific device. You can use the option if you want to boot from one device at a time.

Boot and run Ubuntu from the USB drive Picture 4

Boot from Ubuntu LiveCD

Turn off your computer, then insert the CD drive into the CD/DVD tray on the computer. Next, open your computer and set up the BIOS to boot from the CD drive. It will load and you will see Ubuntu.

If your computer already has Ubuntu installed, you can skip this step. Just open your computer and log in.

Boot and run Ubuntu from the USB drive Picture 5

Format the USB drive

The next step now is to format the USB drive. In this tutorial we will create 2 partitions, one for the actual Ubuntu operating system and one for the other operating system to automatically save changes and settings in the USB drive and restore these settings every time. startup times. In addition, you can also store personal data on the 2nd partition.

Back up all your data on the USB drive before performing the steps. This operation will delete all files and data on your USB drive.

Step 1 : Back up data on your USB drive.

Step 2: Open Terminal located in Applications.

Step 3: Enter sudo su there.

Step 4: Enter fdisk -l there and determine which device is your USB. Suppose if your USB drive is sda, enter " format sda1 " there.

Step 5 : Enter the command " umount /dev/sdb1 ".

Step 6: Enter the command " fdisk /dev/sdb ".

- Enter p to display existing partitions and d to delete that partition.

- Enter p again to display the remaining partitions (if the partition exists, perform the above step to delete the partition).

- Enter n to create a new partition.

- Enter p for primary partition.

- Enter 1 to number the first partition.

Press Enter to use partition 1 as the default partition.

- Enter +750M to set the partition size.

- Enter a to activate the partition.

- Enter 1 to select partition 1.

- Enter t to change file system partition.

- Enter 6 to select fat16 file system.

- Enter n to create a new partition.

- Enter p for primary partition.

- Enter 2 to mark the 2nd partition.

- Press Enter to use the default partition.

- Press Enter again to use the last partition as the default partition.

- Enter w to write a new partition table.

Step 7 : Enter the command umount /dev/sdb1 , then enter umount /dev/sdb2.

Step 8 : Enter the command mkfs.vfat -F 16 -n Ubuntu /dev/sdb1 . This command to format the first partition.

Step 9 : Next enter the command mkfs.ext2 -b 4096 -L casper-rw /dev/sdb2 to format the second partition.

Step 10: Close the Terminal window and remove the USB drive.

Install Ubuntu to the USB drive

After completing the USB drive formatting process, the next step is now to install Ubuntu onto the USB drive partition.

Step 1: Plug the USB drive into the computer.

Step 2: Open Terminal.

Step 3 : Enter the command apt-get update.

Step 4 : Access Ubuntu Packages, download Mtools to your computer and install. Next, download Syslinux and install.

Download Mtools to your computer and install here: Download MTools

Download Syslinux to your computer and install it here: Download Syslinux

Boot and run Ubuntu from the USB drive Picture 6

Boot and run Ubuntu from the USB drive Picture 7

Step 5 : On the Terminal window, enter the command syslinux -sf /dev/sdb1 .

Step 6 : Enter cd /cdrom.

Step 7: Enter the command " cp -rf casper disctree dists install pics pool preseed .disk isolinux/* md5sum.txt README.diskdefines ubuntu.ico casper/vmlinuz casper/initrd.gz /media/Ubuntu/".

Ignore any "cannot create symbolic link" errors.

Step 8 : Access the first partition on the USB drive and rename isolinux.cfg to syslinux.cfg .

Step 9 : Edit syslinux.cfg like the file attached HERE

Completed

Just restart the computer, and set it to boot from the USB drive in the BIOS.

If you cannot boot and run Ubuntu from the USB drive, it is likely that your USB drive has an MBR error. To fix MBR errors on a USB drive, in the Terminal window on Ubuntu, enter the command below:

sudo apt-get install lilo

Then enter the command lilo -M /dev/sdb .

Boot and run Ubuntu from the USB drive Picture 8

From now on you can run Ubuntu anywhere and have all the necessary settings and files available.


Above TipsMake has just shown you how to boot and run Ubuntu from a USB drive. If you do not want to continue running Ubuntu from a USB drive but want to install it directly on your computer, you can choose to install Ubuntu in parallel with Windows 10, 8, 7 UEFI and GPT which is also quite simple and easy.

4 ★ | 1 Vote

May be interested

  • 5 things to do after upgrading to Ubuntu 22.04 LTS5 things to do after upgrading to Ubuntu 22.04 LTS
    ubuntu 22.04 lts jammy jellyfish is the latest version of the popular open source operating system ubuntu. installing a fresh copy on a freshly wiped hard drive will give you a great computing experience.
  • How to Install Windows from UbuntuHow to Install Windows from Ubuntu
    this article will show you how to install windows 10 on a personal computer (pc) running ubuntu linux. before you begin, make sure you have purchased a windows license and have the product key. if you don't have the windows installation file, don't worry because you can create a usb drive to boot from the downloaded iso image. after installing windows, you can install the easybcd tool that allows you to switch between operating systems at startup.
  • What's New in Ubuntu 21.10?What's New in Ubuntu 21.10?
    version 21.10 is the latest release of ubuntu and although canonical is turning more attention to the cloud and developers, ubuntu 'impish indri' still comes with some notable changes for those users use the ubuntu desktop every day.
  • Ways to install Ubuntu on Windows, run in parallel or run separatelyWays to install Ubuntu on Windows, run in parallel or run separately
    there are many ways to install ubuntu on your computer, such as installing ubuntu from usb, cd, installing ubuntu running in parallel with windows, installing it
  • How to set up BIOS to boot from USB / CD / DVD, external hard driveHow to set up BIOS to boot from USB / CD / DVD, external hard drive
    when installing a new computer or reinstalling the win, it is necessary to set the bios settings to select boot from the support tools. if users install win using devices such as usb / cd / dvd or external hard drive, it is necessary to set up the bios to run with the corresponding boot device.
  • How to safely uninstall Ubuntu from dual boot Windows PCHow to safely uninstall Ubuntu from dual boot Windows PC
    you need to uninstall ubuntu from your pc. but how to do this safely without losing data from ubuntu or windows?
  • How to fix the error is not logged in UbuntuHow to fix the error is not logged in Ubuntu
    one of the most common and controversial errors that ubuntu users encounter is the login boot loop. when you try to log in to ubuntu after booting, you will be taken back to the login screen and the process is infinite.
  • How to Format a Hard Drive on UbuntuHow to Format a Hard Drive on Ubuntu
    you can format the drive using the disks utility that comes pre-installed on ubuntu. if the disks utility reports an error or the partition is damaged, you can use gparted to format it. in addition, gparted can also resize existing partitions, allowing you to create additional partitions from an empty drive.
  • How to speed up Ubuntu systemHow to speed up Ubuntu system
    ubuntu is a really powerful open source operating system, for some mid-range computers customizing the system will help this aging system make the most of its potential. .
  • Create Hiren's BootCD from USB driveCreate Hiren's BootCD from USB drive
    have you ever encountered a computer without a cd drive or a drive that has been corrupted and you want to reinstall the computer from a ghost set available on your computer?