14

I am unable to install Ubuntu 18.04.

To start things off, I see a black screen instead of installation instruction after booting the liveusb using BIOS boot (not UEFI). Not sure why this black screen but I am guessing its a graphics driver issue. I am using a newly bought amd rx560 card.

But I did however gain access to the OS by setting 'nomodeset'. Unfortunately at the end of the installation process, it failed to install the GRUB, giving me the error message shown in the title of this question.

I usually have two partitions for any linux distro: swap and root. I also leave the "Device for bootloader installation" option untouched. Which is by default /dev/sda

Please feel free to ask me any information regarding this. I really need help on this. I don't want to go back to windows after 9 years of ubuntuship.

Eisenheim
  • 449
  • 2
  • 5
  • 15

4 Answers4

16

Try this if it makes sense to you:

  1. Boot Ubuntu Live DVD/USB in testing mode and open terminal

  2. Run installation process without installing boot loader by:

    sudo ubiquity -b
    
  3. Press Continue testing after installation is over.

  4. Mount the newly installed file system into /mnt:

    sudo mount /dev/sda2 /mnt
    sudo mkdir /mnt/boot/efi
    sudo mount /dev/sda1 /mnt/boot/efi
    for i in /dev /dev/pts /proc /sys; do sudo mount -B $i /mnt$i; done
    

    (Where sda2 is the root partition and sda1 is the EFI partition.)

  5. Load the efivars module by:

    sudo modprobe efivars
    
  6. Reinstall grub-install for a 64-bit version:

    sudo apt-get install --reinstall grub-efi-amd64-signed
    sudo grub-install --no-nvram --root-directory=/mnt
    
  7. Change root to /mnt and update Grub:

    sudo chroot /mnt
    update-grub
    
  8. Move and rename the installed boot loader:

    cd /boot/efi/EFI
    cp -R ubuntu/* BOOT/
    cd BOOT
    cp grubx64.efi bootx64.efi
    
  9. Reboot the system.

Velkan
  • 3,681
10

Create an EFI file system partition sized 1024mb while installing. I choose custom partition as following and its working fine:

HDD1 (/dev/sda)

  • Device: /dev/sda1
  • Partition type: EFI System (FAT)
  • size: 1.0 GB

  • Device: /dev/sda2
  • Partition type: Linux swap (Swap)
  • size: 16 GB

  • Device: /dev/sda3
  • Partition type: Linux File System (Ext4)
  • size: Rest of the space available in this HDD
  • mount point: /

HDD2 (/dev/sdb)

  • Device: /dev/sdb1
  • Partition type: Linux File System (Ext4)
  • size: All available space in this HDD
  • mount point: /home
David Foerster
  • 36,890
  • 56
  • 97
  • 151
3

This bug has three workarounds:

It's a real bug in the Ubuntu installer and should be fixed asap, it affects a lot of people.

David Foerster
  • 36,890
  • 56
  • 97
  • 151
3

I had same problem and I fixed it. Go to your boot device menu and pick your liveUSB but not the UEFI one (UEFI:Jetflash........).


UEFI Boot Mode (installing using the GPT partition style) and Legacy BIOS Boot Mode (installing using the MBR partition style)

To know the difference you can search this: UEFI Boot Mode or Legacy BIOS Boot Mode

H Ketabi
  • 171