2

Goal: I am trying to install Ubuntu onto a Dell XPS 8900.

Problem: I can't get through an Ubuntu install without the install interrupting with Unable to install Grub in /dev/sda, Executing 'grub-install /dev/sda failed.' This is a fatal error..

Installer: I am using a flash drive with Ubuntu 22.04 LTS Installer on it. I have tried with a flash drive that I have installed with before and I have tried with a fresh install on another flash drive that I created with the Startup Disk Creator application. Note: I have added nomodeset and acpi=off in my grub command to start the Ubuntu Installer OS.

Attempts to solve:

  • I tried to complete the grub-install myself using some answers on askubuntu. I did the aforementioned fix by exiting the installer prompt (after it failed) and running the commands in the terminal. I was able to successfully complete the grub-install here. However, as the original error happens part way into an install the resulting Ubuntu OS had multiple problems. I had services that would fail or just not start (including but not limited to: networkd-dispatcher.service, NetworkManager.service, fwupd-refresh.service, apparmor.service, caspermd5.services(?) ) and I had left over remnants from the install (for example, an application named Install RELEASE was still in my applications).

    • Note: chrooting into /mnt and running grub-install /dev/sda results in unable to allocate pty: No such device
  • Top answer here suggests clicking Try Ubuntu and the using the Install Ubuntu 24.04 LTS application, which didn't work for me.

  • Top answer here suggests that grub-install is installing to the wrong device, which isn't true for me.

  • I am desperate now, so I updated the BIOS to its most recent update. That didn't do anything.

  • I tried running grub-install prior to running the Try Install application.

    • Note: running sudo grub-install --root-directory /mnt /dev/sda results in grub-instal: error: failed to register the EFI boot entry: Operation not permitted.
    • Also, I worry that even if I could successfully run grub-install prior to running the Ubuntu Installer, that the Ubuntu Installer would still fail because the Ubuntu Installer might run grub-install without options.

Question: Why does Ubuntu 22.04 LTS install continue to fail with 'grub-install /dev/sda failed' error?

Output from sudo fdisk -l:

<multiple /dev/loopN>
....
Disk /dev/sda: 1.82 TiB, ......
Device       Size    Type
/dev/sda1    512M    EFI System
/dev/sda2    1.8T    Linux Filesystem

Disk /dev/sdb: 14.45 GiB, ......
Device      Size    Type
/dev/sdb1   3.6G    Microsoft basic data
/dev/sdb2   4.1M    EFI System
/dev/sdb3   300K    Microsoft basic data
/dev/sdb4   10.9G   Linux Filesystem
....
<multiple /dev/loop<N>>

Output from lsblk:

NAME  TYPE  MOUNTPOINTS
<multiple loop<N>>
...
sda   disk
sda1  part
sda2  part
sdb   disk   /cdrom
sdb1  part
sdb2  part
sdb3  part
sdb4  part   /var/crash
             /var/log
sdc   disk
sdd   disk
sde   disk
sdf   disk
sr0   rom

Output of grub-install --version:

grub-install (GRUB) 2.06-2ubuntu7

Output of sudo gdisk /dev/sda:

GPT fdisk (gdisk) version 1.0.8

Partition table scan:
  MBR: protective
  BSD: not present
  APM: not present
  GPT: present

Found valid GPT with protective MBR; using GPT.

Output of sudo gdisk /dev/sda then p:

Number  Size   Code   Name
  1    512MiB  EF00   EFI System Partition
  2    1.8TiB  8300
MrDrago9
  • 31
  • 3
  • Comments are not for extended discussion; this conversation has been [moved to chat](https://chat.stackexchange.com/rooms/139512/discussion-on-question-by-mrdrago9-why-does-ubuntu-22-04-lts-install-continue-to). – andrew.46 Sep 28 '22 at 22:53
  • Thanks @andrew.46. I would have done it, but I don't have enough rep. – MrDrago9 Sep 28 '22 at 23:09
  • Hi , I have this problem too, what did you do at the end? – Parisa.H.R May 28 '23 at 14:33

0 Answers0