Can I install Ubuntu in a USB stick and run it as my learning machine? Will it run as a normal Ubuntu without difference? [closed]

Solution 1:

Can I install Ubuntu in a USB stick and run it as my learning machine?

Yes.

In UEFI mode, the Ubuntu bootloader will always be installed into the first drive, which is usually an internal drive. If you want to get the [UEFI] bootloader (which is a partition) into a USB drive, you can unplug, disconnect or otherwise disable the internal drive.

In BIOS mode alias CSM alias legacy mode you can control where Ubuntu installs the bootloader. But it is always a good idea to unplug, disconnect or otherwise disable the internal drive in order to get the bootloader into the USB drive, when that is what you want.

See the following links,

Step-wise instructions for installed system in a USB drive

How to Create a Full Install of Ubuntu 20.04 to USB Device Step by Step

If you need not encrypt the drive, there is an easy alternative. You can use a compressed image

Will it run as a normal Ubuntu without difference?

Almost.

It will be slower, when you use a USB stick. If you use an SSD connected via USB (in an external box or connected via a USB to SATA adapter) if can be fast, almost as fast as an internal drive.

Will it work perfectly?

No.

  • A USB stick or memory card has memory cells that wear faster than a HDD or SSD. It has a limited number of write operations and there is electronics for wear levelling. Both of these can fail without a warning. So it is important to backup everything that you cannot afford to lose.

    There are methods to decrease the wear, but at a cost. Methods to recover from write failures and corruption of the file system cause wear. You can turn them off. This is described at this link.

  • If your Windows 10 system is installed in UEFI mode, major upgrades may destroy the bootloader of your external drive. So check that the USB drive with Ubuntu is unplugged, when you boot Windows.

Solution 2:

Full Install vs Persistent install

Comparison between Persistent and Full install USB

Advantages of a persistent install:

  1. You can use the persistent pendrive to install Ubuntu to another computer.

  2. A persistent install takes up less space on the pendrive.

  3. You can reset the pendrive by overwriting the old casper-rw file with a new one.

  4. The install to pendrive takes less time.

Advantages of a Full install:

  1. You can update and upgrade.

  2. If you have problems or wish to modify, the solution is the same as with an internal install, (You can ask for help in these forums).

  3. No ugly startup / install screen.

  4. Better security, you can use full encryption

  5. You can use proprietary drivers.

  6. Hibernation works.

  7. A persistent install is limited to a 4GB casper-rw and a 4GB home-rw persistence file, to get more persistence requires persistence partitions. Once casper-rw is full, the drive will not boot.

  8. More efficient usage of disk space. Does not require reserved space for persistence.

  9. Faster boot, no automatic disk checking or Try Ubuntu/Install Ubuntu screen.

  10. You can run VBox and use virtual machines.

Note that once booted, both methods run at about the same speed. If the computer has lots of RAM Ubuntu should run mainly in RAM and there will not be a bi difference between running off internal HDD and USB3 flash drive.

Full Install Method Three methods for creating a Full install USB: How to Create a Full Install of Ubuntu 20.04 to USB Device Step by Step