Custom Ubuntu image is broken after Grub update (when using UEFI)











up vote
2
down vote

favorite












So I've been working on creating a custom Ubuntu 16.04.5 image. I follow the instructions here to chroot into the file system that gets put onto the computers and do apt update && apt full-upgrade. After that I package everything up into an ISO and use that to image a computer. I do most of my testing in VirtualBox & when I tell the VM to boot using UEFI, the Ubuntu installation gives me an error:



The 'grub-efi-amd64-signed' package failed to install into /target/.
Without the GRUB boot loader, the installed system will not boot.


So I went back to the chroot environment, installed the 'grub-efi-amd64-signed' package (there's no internet connection during the install process), and all is well. This was working fine for me until recently. Now, after the installation I'm now taken to the Grub command prompt.



Now it seems there's an update to Grub2; from 2.02~beta2-36ubuntu3.18 to 3.19. If I don't install that update I can't use UEFI because of that error I get. If I install the 'grub-efi-amd64-signed' then if forces the other Grub packages to update. If I DO install that package & all the updates, then the computer boots to the Grub command prompt. I really don't know where to begin to fix this. What can I do to update Grub & fix the issue?



Could this be because the ISO is using the previous version of Grub?



EDIT: Something else I've noticed. I'm able to get everything to install (and boot) correctly if I apt-mark hold on the following packages:



linux-generic-hwe-16.04
linux-image-generic-hwe-16.04
linux-headers-generic-hwe-16.04
linux-signed-generic-hwe-16.04
grub-common
grub2-common


After that, I can apt full-upgrade, create the ISO & do the install... So why does it break when I update the kernel & Grub?



FWIW, here's my preseed file:



### Localization
d-i debian-installer/locale string en_US
d-i console-setup/ask_detect boolean false
d-i console-setup/layoutcode string us


### Network Configuration
d-i netcfg/dhcp_timeout string 300
d-i netcfg/dhcp_failed note
d-i netcfg/dhcp_options select Do not configure the network at this time
d-i netcfg/get_hostname string dev
d-i netcfg/get_domain string example.com


### Account Setup
d-i passwd/user-fullname string User
d-i passwd/username string user
d-i passwd/user-password-crypted password $6$...
d-i user-setup/allow-password-weak boolean true
d-i user-setup/encrypt-home boolean false


### Clock and Time Zone Setup
d-i clock-setup/utc boolean true
d-i time/zone string US/Eastern
d-i clock-setup/ntp boolean true


### Partitioning and Encryption
# Use LVM for encryption
d-i partman-auto/method string crypto

# Suppress LVM and RAID warnings about previous configurations
d-i partman-lvm/device_remove_lvm boolean true
d-i partman-md/device_remove_md boolean true

# Confirm writing on existing partitions
d-i partman-lvm/confirm boolean true

# Use the entire logical volume
d-i partman-auto-lvm/guided_size string max

# Have all files on this partition only
d-i partman-auto/choose_recipe select atomic

# Specify ext4 since the default is ext3
d-i partman/default_filesystem string ext4

# Begin the partitioning without user interaction
d-i partman-partitioning/confirm_write_new_label boolean true
d-i partman/choose_partition select finish
d-i partman/confirm boolean true
d-i partman/confirm_nooverwrite boolean true

# Use the encryption key to perform the encryption
partman-crypto partman-crypto/passphrase string password
partman-crypto partman-crypto/passphrase-again string password

# Agree to use weak passphrase and confirm if prompted
partman-crypto partman-crypto/weak_passphrase boolean true
partman-crypto partman-crypto/confirm boolean true


### Package Selection
tasksel tasksel/first multiselect standard
tasksel tasksel/first multiselect ubuntu-desktop
d-i pkgsel/updatedb boolean false


### Boot Loader Installation
d-i grub-installer/only_debian boolean true


### Finishing Up the Installation
ubiquity ubiquity/reboot boolean true









share|improve this question




























    up vote
    2
    down vote

    favorite












    So I've been working on creating a custom Ubuntu 16.04.5 image. I follow the instructions here to chroot into the file system that gets put onto the computers and do apt update && apt full-upgrade. After that I package everything up into an ISO and use that to image a computer. I do most of my testing in VirtualBox & when I tell the VM to boot using UEFI, the Ubuntu installation gives me an error:



    The 'grub-efi-amd64-signed' package failed to install into /target/.
    Without the GRUB boot loader, the installed system will not boot.


    So I went back to the chroot environment, installed the 'grub-efi-amd64-signed' package (there's no internet connection during the install process), and all is well. This was working fine for me until recently. Now, after the installation I'm now taken to the Grub command prompt.



    Now it seems there's an update to Grub2; from 2.02~beta2-36ubuntu3.18 to 3.19. If I don't install that update I can't use UEFI because of that error I get. If I install the 'grub-efi-amd64-signed' then if forces the other Grub packages to update. If I DO install that package & all the updates, then the computer boots to the Grub command prompt. I really don't know where to begin to fix this. What can I do to update Grub & fix the issue?



    Could this be because the ISO is using the previous version of Grub?



    EDIT: Something else I've noticed. I'm able to get everything to install (and boot) correctly if I apt-mark hold on the following packages:



    linux-generic-hwe-16.04
    linux-image-generic-hwe-16.04
    linux-headers-generic-hwe-16.04
    linux-signed-generic-hwe-16.04
    grub-common
    grub2-common


    After that, I can apt full-upgrade, create the ISO & do the install... So why does it break when I update the kernel & Grub?



    FWIW, here's my preseed file:



    ### Localization
    d-i debian-installer/locale string en_US
    d-i console-setup/ask_detect boolean false
    d-i console-setup/layoutcode string us


    ### Network Configuration
    d-i netcfg/dhcp_timeout string 300
    d-i netcfg/dhcp_failed note
    d-i netcfg/dhcp_options select Do not configure the network at this time
    d-i netcfg/get_hostname string dev
    d-i netcfg/get_domain string example.com


    ### Account Setup
    d-i passwd/user-fullname string User
    d-i passwd/username string user
    d-i passwd/user-password-crypted password $6$...
    d-i user-setup/allow-password-weak boolean true
    d-i user-setup/encrypt-home boolean false


    ### Clock and Time Zone Setup
    d-i clock-setup/utc boolean true
    d-i time/zone string US/Eastern
    d-i clock-setup/ntp boolean true


    ### Partitioning and Encryption
    # Use LVM for encryption
    d-i partman-auto/method string crypto

    # Suppress LVM and RAID warnings about previous configurations
    d-i partman-lvm/device_remove_lvm boolean true
    d-i partman-md/device_remove_md boolean true

    # Confirm writing on existing partitions
    d-i partman-lvm/confirm boolean true

    # Use the entire logical volume
    d-i partman-auto-lvm/guided_size string max

    # Have all files on this partition only
    d-i partman-auto/choose_recipe select atomic

    # Specify ext4 since the default is ext3
    d-i partman/default_filesystem string ext4

    # Begin the partitioning without user interaction
    d-i partman-partitioning/confirm_write_new_label boolean true
    d-i partman/choose_partition select finish
    d-i partman/confirm boolean true
    d-i partman/confirm_nooverwrite boolean true

    # Use the encryption key to perform the encryption
    partman-crypto partman-crypto/passphrase string password
    partman-crypto partman-crypto/passphrase-again string password

    # Agree to use weak passphrase and confirm if prompted
    partman-crypto partman-crypto/weak_passphrase boolean true
    partman-crypto partman-crypto/confirm boolean true


    ### Package Selection
    tasksel tasksel/first multiselect standard
    tasksel tasksel/first multiselect ubuntu-desktop
    d-i pkgsel/updatedb boolean false


    ### Boot Loader Installation
    d-i grub-installer/only_debian boolean true


    ### Finishing Up the Installation
    ubiquity ubiquity/reboot boolean true









    share|improve this question


























      up vote
      2
      down vote

      favorite









      up vote
      2
      down vote

      favorite











      So I've been working on creating a custom Ubuntu 16.04.5 image. I follow the instructions here to chroot into the file system that gets put onto the computers and do apt update && apt full-upgrade. After that I package everything up into an ISO and use that to image a computer. I do most of my testing in VirtualBox & when I tell the VM to boot using UEFI, the Ubuntu installation gives me an error:



      The 'grub-efi-amd64-signed' package failed to install into /target/.
      Without the GRUB boot loader, the installed system will not boot.


      So I went back to the chroot environment, installed the 'grub-efi-amd64-signed' package (there's no internet connection during the install process), and all is well. This was working fine for me until recently. Now, after the installation I'm now taken to the Grub command prompt.



      Now it seems there's an update to Grub2; from 2.02~beta2-36ubuntu3.18 to 3.19. If I don't install that update I can't use UEFI because of that error I get. If I install the 'grub-efi-amd64-signed' then if forces the other Grub packages to update. If I DO install that package & all the updates, then the computer boots to the Grub command prompt. I really don't know where to begin to fix this. What can I do to update Grub & fix the issue?



      Could this be because the ISO is using the previous version of Grub?



      EDIT: Something else I've noticed. I'm able to get everything to install (and boot) correctly if I apt-mark hold on the following packages:



      linux-generic-hwe-16.04
      linux-image-generic-hwe-16.04
      linux-headers-generic-hwe-16.04
      linux-signed-generic-hwe-16.04
      grub-common
      grub2-common


      After that, I can apt full-upgrade, create the ISO & do the install... So why does it break when I update the kernel & Grub?



      FWIW, here's my preseed file:



      ### Localization
      d-i debian-installer/locale string en_US
      d-i console-setup/ask_detect boolean false
      d-i console-setup/layoutcode string us


      ### Network Configuration
      d-i netcfg/dhcp_timeout string 300
      d-i netcfg/dhcp_failed note
      d-i netcfg/dhcp_options select Do not configure the network at this time
      d-i netcfg/get_hostname string dev
      d-i netcfg/get_domain string example.com


      ### Account Setup
      d-i passwd/user-fullname string User
      d-i passwd/username string user
      d-i passwd/user-password-crypted password $6$...
      d-i user-setup/allow-password-weak boolean true
      d-i user-setup/encrypt-home boolean false


      ### Clock and Time Zone Setup
      d-i clock-setup/utc boolean true
      d-i time/zone string US/Eastern
      d-i clock-setup/ntp boolean true


      ### Partitioning and Encryption
      # Use LVM for encryption
      d-i partman-auto/method string crypto

      # Suppress LVM and RAID warnings about previous configurations
      d-i partman-lvm/device_remove_lvm boolean true
      d-i partman-md/device_remove_md boolean true

      # Confirm writing on existing partitions
      d-i partman-lvm/confirm boolean true

      # Use the entire logical volume
      d-i partman-auto-lvm/guided_size string max

      # Have all files on this partition only
      d-i partman-auto/choose_recipe select atomic

      # Specify ext4 since the default is ext3
      d-i partman/default_filesystem string ext4

      # Begin the partitioning without user interaction
      d-i partman-partitioning/confirm_write_new_label boolean true
      d-i partman/choose_partition select finish
      d-i partman/confirm boolean true
      d-i partman/confirm_nooverwrite boolean true

      # Use the encryption key to perform the encryption
      partman-crypto partman-crypto/passphrase string password
      partman-crypto partman-crypto/passphrase-again string password

      # Agree to use weak passphrase and confirm if prompted
      partman-crypto partman-crypto/weak_passphrase boolean true
      partman-crypto partman-crypto/confirm boolean true


      ### Package Selection
      tasksel tasksel/first multiselect standard
      tasksel tasksel/first multiselect ubuntu-desktop
      d-i pkgsel/updatedb boolean false


      ### Boot Loader Installation
      d-i grub-installer/only_debian boolean true


      ### Finishing Up the Installation
      ubiquity ubiquity/reboot boolean true









      share|improve this question















      So I've been working on creating a custom Ubuntu 16.04.5 image. I follow the instructions here to chroot into the file system that gets put onto the computers and do apt update && apt full-upgrade. After that I package everything up into an ISO and use that to image a computer. I do most of my testing in VirtualBox & when I tell the VM to boot using UEFI, the Ubuntu installation gives me an error:



      The 'grub-efi-amd64-signed' package failed to install into /target/.
      Without the GRUB boot loader, the installed system will not boot.


      So I went back to the chroot environment, installed the 'grub-efi-amd64-signed' package (there's no internet connection during the install process), and all is well. This was working fine for me until recently. Now, after the installation I'm now taken to the Grub command prompt.



      Now it seems there's an update to Grub2; from 2.02~beta2-36ubuntu3.18 to 3.19. If I don't install that update I can't use UEFI because of that error I get. If I install the 'grub-efi-amd64-signed' then if forces the other Grub packages to update. If I DO install that package & all the updates, then the computer boots to the Grub command prompt. I really don't know where to begin to fix this. What can I do to update Grub & fix the issue?



      Could this be because the ISO is using the previous version of Grub?



      EDIT: Something else I've noticed. I'm able to get everything to install (and boot) correctly if I apt-mark hold on the following packages:



      linux-generic-hwe-16.04
      linux-image-generic-hwe-16.04
      linux-headers-generic-hwe-16.04
      linux-signed-generic-hwe-16.04
      grub-common
      grub2-common


      After that, I can apt full-upgrade, create the ISO & do the install... So why does it break when I update the kernel & Grub?



      FWIW, here's my preseed file:



      ### Localization
      d-i debian-installer/locale string en_US
      d-i console-setup/ask_detect boolean false
      d-i console-setup/layoutcode string us


      ### Network Configuration
      d-i netcfg/dhcp_timeout string 300
      d-i netcfg/dhcp_failed note
      d-i netcfg/dhcp_options select Do not configure the network at this time
      d-i netcfg/get_hostname string dev
      d-i netcfg/get_domain string example.com


      ### Account Setup
      d-i passwd/user-fullname string User
      d-i passwd/username string user
      d-i passwd/user-password-crypted password $6$...
      d-i user-setup/allow-password-weak boolean true
      d-i user-setup/encrypt-home boolean false


      ### Clock and Time Zone Setup
      d-i clock-setup/utc boolean true
      d-i time/zone string US/Eastern
      d-i clock-setup/ntp boolean true


      ### Partitioning and Encryption
      # Use LVM for encryption
      d-i partman-auto/method string crypto

      # Suppress LVM and RAID warnings about previous configurations
      d-i partman-lvm/device_remove_lvm boolean true
      d-i partman-md/device_remove_md boolean true

      # Confirm writing on existing partitions
      d-i partman-lvm/confirm boolean true

      # Use the entire logical volume
      d-i partman-auto-lvm/guided_size string max

      # Have all files on this partition only
      d-i partman-auto/choose_recipe select atomic

      # Specify ext4 since the default is ext3
      d-i partman/default_filesystem string ext4

      # Begin the partitioning without user interaction
      d-i partman-partitioning/confirm_write_new_label boolean true
      d-i partman/choose_partition select finish
      d-i partman/confirm boolean true
      d-i partman/confirm_nooverwrite boolean true

      # Use the encryption key to perform the encryption
      partman-crypto partman-crypto/passphrase string password
      partman-crypto partman-crypto/passphrase-again string password

      # Agree to use weak passphrase and confirm if prompted
      partman-crypto partman-crypto/weak_passphrase boolean true
      partman-crypto partman-crypto/confirm boolean true


      ### Package Selection
      tasksel tasksel/first multiselect standard
      tasksel tasksel/first multiselect ubuntu-desktop
      d-i pkgsel/updatedb boolean false


      ### Boot Loader Installation
      d-i grub-installer/only_debian boolean true


      ### Finishing Up the Installation
      ubiquity ubiquity/reboot boolean true






      boot grub2 uefi grub-efi






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Dec 10 at 18:05

























      asked Dec 3 at 19:44









      Andrew Lamarra

      1217




      1217






















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          0
          down vote













          I believe you are running into the same issue found here: 16.04 new installation gives grub-efi-amd64-signed failed installation /target/ ubuntu 16.04 at the end



          I think you need to create the /boot/efi partition manually and mark it with a boot flag. We ran into this recently and resolved with preseeds like below, edit for your drive if needed. This will create the correct partitions, use the entire disk (up to 1000 TB) and swap (8 GB or 2xRAM):



          d-i partman-auto/disk                            string /dev/sda
          d-i partman-auto/method string crypto
          d-i partman-lvm/device_remove_lvm boolean true
          d-i partman-lvm/device_remove_lvm_span boolean true
          d-i partman-auto/purge_lvm_from_device boolean true
          d-i partman-auto-lvm/new_vg_name string system
          d-i partman-auto/expert_recipe string
          boot-crypto ::
          1 1 1 free
          $bios_boot{ }
          method{ biosgrub } .
          256 256 256 fat32
          $primary{ } $lvmignore{ }
          method{ efi } format{ } .
          512 512 512 ext3
          $primary{ } $bootable{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext3 }
          mountpoint{ /boot } .
          2000 10000 1000000000 ext4
          $lvmok{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext4 }
          mountpoint{ / } .
          8000 8000 200% linux-swap
          $lvmok{ }
          method{ swap } format{ } .
          d-i partman-lvm/confirm boolean true
          d-i partman-partitioning/confirm_write_new_label boolean true
          d-i partman/choose_partition select finish
          d-i partman/confirm boolean true
          d-i partman/confirm_nooverwrite boolean true





          share|improve this answer





















          • Thanks, I'll try this when I'm back at work next week.
            – Andrew Lamarra
            Dec 6 at 15:31










          • Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
            – Andrew Lamarra
            Dec 10 at 13:39










          • Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
            – Jarad Downing
            Dec 11 at 14:28










          • So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
            – Andrew Lamarra
            Dec 12 at 14:30













          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "89"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1098228%2fcustom-ubuntu-image-is-broken-after-grub-update-when-using-uefi%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes








          up vote
          0
          down vote













          I believe you are running into the same issue found here: 16.04 new installation gives grub-efi-amd64-signed failed installation /target/ ubuntu 16.04 at the end



          I think you need to create the /boot/efi partition manually and mark it with a boot flag. We ran into this recently and resolved with preseeds like below, edit for your drive if needed. This will create the correct partitions, use the entire disk (up to 1000 TB) and swap (8 GB or 2xRAM):



          d-i partman-auto/disk                            string /dev/sda
          d-i partman-auto/method string crypto
          d-i partman-lvm/device_remove_lvm boolean true
          d-i partman-lvm/device_remove_lvm_span boolean true
          d-i partman-auto/purge_lvm_from_device boolean true
          d-i partman-auto-lvm/new_vg_name string system
          d-i partman-auto/expert_recipe string
          boot-crypto ::
          1 1 1 free
          $bios_boot{ }
          method{ biosgrub } .
          256 256 256 fat32
          $primary{ } $lvmignore{ }
          method{ efi } format{ } .
          512 512 512 ext3
          $primary{ } $bootable{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext3 }
          mountpoint{ /boot } .
          2000 10000 1000000000 ext4
          $lvmok{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext4 }
          mountpoint{ / } .
          8000 8000 200% linux-swap
          $lvmok{ }
          method{ swap } format{ } .
          d-i partman-lvm/confirm boolean true
          d-i partman-partitioning/confirm_write_new_label boolean true
          d-i partman/choose_partition select finish
          d-i partman/confirm boolean true
          d-i partman/confirm_nooverwrite boolean true





          share|improve this answer





















          • Thanks, I'll try this when I'm back at work next week.
            – Andrew Lamarra
            Dec 6 at 15:31










          • Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
            – Andrew Lamarra
            Dec 10 at 13:39










          • Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
            – Jarad Downing
            Dec 11 at 14:28










          • So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
            – Andrew Lamarra
            Dec 12 at 14:30

















          up vote
          0
          down vote













          I believe you are running into the same issue found here: 16.04 new installation gives grub-efi-amd64-signed failed installation /target/ ubuntu 16.04 at the end



          I think you need to create the /boot/efi partition manually and mark it with a boot flag. We ran into this recently and resolved with preseeds like below, edit for your drive if needed. This will create the correct partitions, use the entire disk (up to 1000 TB) and swap (8 GB or 2xRAM):



          d-i partman-auto/disk                            string /dev/sda
          d-i partman-auto/method string crypto
          d-i partman-lvm/device_remove_lvm boolean true
          d-i partman-lvm/device_remove_lvm_span boolean true
          d-i partman-auto/purge_lvm_from_device boolean true
          d-i partman-auto-lvm/new_vg_name string system
          d-i partman-auto/expert_recipe string
          boot-crypto ::
          1 1 1 free
          $bios_boot{ }
          method{ biosgrub } .
          256 256 256 fat32
          $primary{ } $lvmignore{ }
          method{ efi } format{ } .
          512 512 512 ext3
          $primary{ } $bootable{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext3 }
          mountpoint{ /boot } .
          2000 10000 1000000000 ext4
          $lvmok{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext4 }
          mountpoint{ / } .
          8000 8000 200% linux-swap
          $lvmok{ }
          method{ swap } format{ } .
          d-i partman-lvm/confirm boolean true
          d-i partman-partitioning/confirm_write_new_label boolean true
          d-i partman/choose_partition select finish
          d-i partman/confirm boolean true
          d-i partman/confirm_nooverwrite boolean true





          share|improve this answer





















          • Thanks, I'll try this when I'm back at work next week.
            – Andrew Lamarra
            Dec 6 at 15:31










          • Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
            – Andrew Lamarra
            Dec 10 at 13:39










          • Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
            – Jarad Downing
            Dec 11 at 14:28










          • So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
            – Andrew Lamarra
            Dec 12 at 14:30















          up vote
          0
          down vote










          up vote
          0
          down vote









          I believe you are running into the same issue found here: 16.04 new installation gives grub-efi-amd64-signed failed installation /target/ ubuntu 16.04 at the end



          I think you need to create the /boot/efi partition manually and mark it with a boot flag. We ran into this recently and resolved with preseeds like below, edit for your drive if needed. This will create the correct partitions, use the entire disk (up to 1000 TB) and swap (8 GB or 2xRAM):



          d-i partman-auto/disk                            string /dev/sda
          d-i partman-auto/method string crypto
          d-i partman-lvm/device_remove_lvm boolean true
          d-i partman-lvm/device_remove_lvm_span boolean true
          d-i partman-auto/purge_lvm_from_device boolean true
          d-i partman-auto-lvm/new_vg_name string system
          d-i partman-auto/expert_recipe string
          boot-crypto ::
          1 1 1 free
          $bios_boot{ }
          method{ biosgrub } .
          256 256 256 fat32
          $primary{ } $lvmignore{ }
          method{ efi } format{ } .
          512 512 512 ext3
          $primary{ } $bootable{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext3 }
          mountpoint{ /boot } .
          2000 10000 1000000000 ext4
          $lvmok{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext4 }
          mountpoint{ / } .
          8000 8000 200% linux-swap
          $lvmok{ }
          method{ swap } format{ } .
          d-i partman-lvm/confirm boolean true
          d-i partman-partitioning/confirm_write_new_label boolean true
          d-i partman/choose_partition select finish
          d-i partman/confirm boolean true
          d-i partman/confirm_nooverwrite boolean true





          share|improve this answer












          I believe you are running into the same issue found here: 16.04 new installation gives grub-efi-amd64-signed failed installation /target/ ubuntu 16.04 at the end



          I think you need to create the /boot/efi partition manually and mark it with a boot flag. We ran into this recently and resolved with preseeds like below, edit for your drive if needed. This will create the correct partitions, use the entire disk (up to 1000 TB) and swap (8 GB or 2xRAM):



          d-i partman-auto/disk                            string /dev/sda
          d-i partman-auto/method string crypto
          d-i partman-lvm/device_remove_lvm boolean true
          d-i partman-lvm/device_remove_lvm_span boolean true
          d-i partman-auto/purge_lvm_from_device boolean true
          d-i partman-auto-lvm/new_vg_name string system
          d-i partman-auto/expert_recipe string
          boot-crypto ::
          1 1 1 free
          $bios_boot{ }
          method{ biosgrub } .
          256 256 256 fat32
          $primary{ } $lvmignore{ }
          method{ efi } format{ } .
          512 512 512 ext3
          $primary{ } $bootable{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext3 }
          mountpoint{ /boot } .
          2000 10000 1000000000 ext4
          $lvmok{ }
          method{ format } format{ }
          use_filesystem{ } filesystem{ ext4 }
          mountpoint{ / } .
          8000 8000 200% linux-swap
          $lvmok{ }
          method{ swap } format{ } .
          d-i partman-lvm/confirm boolean true
          d-i partman-partitioning/confirm_write_new_label boolean true
          d-i partman/choose_partition select finish
          d-i partman/confirm boolean true
          d-i partman/confirm_nooverwrite boolean true






          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Dec 5 at 22:21









          Jarad Downing

          1




          1












          • Thanks, I'll try this when I'm back at work next week.
            – Andrew Lamarra
            Dec 6 at 15:31










          • Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
            – Andrew Lamarra
            Dec 10 at 13:39










          • Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
            – Jarad Downing
            Dec 11 at 14:28










          • So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
            – Andrew Lamarra
            Dec 12 at 14:30




















          • Thanks, I'll try this when I'm back at work next week.
            – Andrew Lamarra
            Dec 6 at 15:31










          • Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
            – Andrew Lamarra
            Dec 10 at 13:39










          • Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
            – Jarad Downing
            Dec 11 at 14:28










          • So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
            – Andrew Lamarra
            Dec 12 at 14:30


















          Thanks, I'll try this when I'm back at work next week.
          – Andrew Lamarra
          Dec 6 at 15:31




          Thanks, I'll try this when I'm back at work next week.
          – Andrew Lamarra
          Dec 6 at 15:31












          Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
          – Andrew Lamarra
          Dec 10 at 13:39




          Unfortunately, this introduced another problem. Now, during the install, I get an error titled, "Unable to install GRUB in /dev/sda." The text of the message says, "Executing 'grub-install /dev/sda' failed. This is a fatal error." Would you happen to know how I can view the specifics of these error messages either during installation or after? Maybe having a text-based installer would help.
          – Andrew Lamarra
          Dec 10 at 13:39












          Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
          – Jarad Downing
          Dec 11 at 14:28




          Try hitting the escape key while it is installing. Also, you may need to add some more information at the end of what I posted above. See gist.github.com/jaraddowning/78f9a27d71c3d9456d4e4ec566faf21b
          – Jarad Downing
          Dec 11 at 14:28












          So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
          – Andrew Lamarra
          Dec 12 at 14:30






          So I've added those lines and now the error message says, "Executing 'grub-install dummy' failed." And pushing escape did nothing in the GUI installer.
          – Andrew Lamarra
          Dec 12 at 14:30




















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Ask Ubuntu!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.





          Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


          Please pay close attention to the following guidance:


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1098228%2fcustom-ubuntu-image-is-broken-after-grub-update-when-using-uefi%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Mouse cursor on multiple screens with different PPI

          Agildo Ribeiro

          Sometime when accessing a menu: “Ubuntu 16.04 has experienced an internal error”