6

I installed Fedora 34 about a week ago and found out that most of the apps used .deb which Fedora doesn't support, so I was thinking about switching to Ubuntu, BUT I lost my USB drive, so does anyone know how to install Ubuntu 21.04 without USB drive? My laptop uses UEFI, so unetbootin won't work.

Archisman Panigrahi
  • 28,338
  • 18
  • 105
  • 212
  • You can alter grub so it boots a ISO from a drive on the system (I use it in QA-testing on a device without working USB ports). Note: I didn't QA-test Ubuntu 21.04 on that device, and I know changes have been occurring in recent ISOs with live boots, so I can't guarantee it'll work, but I still believe it would – guiverc May 24 '21 at 01:36
  • 2
    How did you install Fedora? If you have an optical drive, then you could always burn the Ubuntu installation ISO to a DVD. It's much slower, but it'll give you an opportunity to relive the glorious 90s – matigo May 24 '21 at 01:36
  • Can't you just select the boot order? – Ken Sharp May 24 '21 at 15:11

2 Answers2

14

Booting ISO from Fedora GRUB2 Menu

The method on this page should work for booting an Ubuntu ISO from the Fedora GRUB bootloader 20.04 booting .iso from GRUB menu No need for a USB here.

To reiterate:

  • Add the following menuentry to /etc/grub.d/40_custom:

    menuentry "isoname ISO" {
      rmmod tpm
      set root=(hdX,Y)
      set isofile="/[path]/[isoname].iso"
          loopback loop $isofile
          linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile toram --
          initrd (loop)/casper/initrd
    }
    

Where (hdX,Y) is the disk and partition the ISO is on, for example /dev/sda3 would be (hd0,3). [path] is the path to the folder the ISO file is in, and [isoname] is the name of the ISO, for example /isos/ubuntu-20.04.2-desktop-amd64.iso is used if the Ubuntu ISO is located in a folder named isos on the root partition. rmmod tpm is only needed when booting in UEFI mode.

  • In Terminal run:

    sudo update-grub
    
  • Reboot and select Ubuntu from the grub menu. Install as usual.

  • Please let us know how this works for you.

C.S.Cameron
  • 19,519
6

Boot Ubuntu on Windows UEFI computer without USB or CD

For a UEFI computer, this method may be simpler than my proceeding answer:

  • Use Windows Disk Management to create FAT32 partition 3GB or larger.

  • Copy/Paste contents of ISO file to new partition.

  • Reboot pressing F12 and select UEFI Ubuntu.

  • Proceed to Ubuntu Installation.

C.S.Cameron
  • 19,519
  • +1 for a great method, so simple, yet it works (only in UEFI mode, but most current computers with Windows run in UEFI mode). – sudodus Aug 11 '21 at 13:13
  • 1
    This method worked well for me, but note that if you are hoping to install Ubuntu on the same disk you're booting from (as I was) you might need to make sure you hit "e" to edit the boot parameters to add toram on the casper line and also manually unmount the boot volume to make sure it can be wiped by the installer. – bjmc Jul 23 '22 at 19:01