#852653 Grub install failed on encrypted LVM disk

#852653#5
Date:
2017-01-26 03:20:02 UTC
From:
To:
Dear Maintainer,

   * What led up to the situation?
        Failed installation of grub under KVM system with encrypted LVM disk.

   * What exactly did you do (or not do) that was effective (or ineffective)?
    Source:
        netinst iso-cd weekly built on 2017-01-23, downloaded from debian website
    System:
        Debian Jessie running qemu-kvm 1:2.1+dfsg-12+deb8u6
    KVM hardware:
        1 x IDE CDROM (debian-testing netinst iso-cd)
        1 x 8GB virtio disk (vda)
        1 x virtio network adapter
        QXL display
    Partition disks:
        Encrypte vda disk and setup with LVM:
            Encrypted volume (vda1_crypt) - 8.6GB
                #1  8.6GB    K    lvm
            LVM VG vg, LV lvhome - 4.1GB
                #1  4.1GB    K    ext4    /home
            LVM VG vg, LV lvroot - 4.1GB
                #1  4.1GB    K    ext4    /
            LVM VG vg, LV lvswap - 255.9MB
                #1  255.9MB  K    swap    swap
            Virtual disk 1 (vda) - 8.6GB Virtio Block Device
                #1  primary 8.6GB K crypto
    GRUB installation:
        Install the GRUB boot loader to the master boot record --> Yes
        Device for boot loader installation: /dev/vda
        Force GRUB installation to the EFI removable media path? Yes

   * What was the outcome of this action?
    Error message:
        Unable to install GRUB in /dev/vda
        Executing 'grub-install /dev/vda' failed.
        This is a fatal error.

   * What outcome did you expect instead?
    Installation of grub completed.

#852653#10
Date:
2017-01-26 04:38:19 UTC
From:
To:
Dear Maintainer:

Problem solved.  Mark "BOOT" flag in the encrypted disk.  Then grub install completed successfully.

Suggest to verify BOOT flag has been marked to allow proceeding to next installation stage.

Regards,

Alan

#852653#15
Date:
2017-01-26 08:42:40 UTC
From:
To:
Dear Maintainer:

Another test found that the detection of "Encryption configuration failure" exist while failed if the disk is configured as in case #2:

#1. For below disk partition setup,  "Encryption configuration failure ... You should go back and setup a /boot partition" show correctly.

    vda -->
        vda_crypto -->
            vg -->
                 lv /

#2.  For below disk partition setup, no warning message and the system keep install until grub installation stage shows failed to isntall grub error:

    vda -->
        vda_crypto -->
            vg -->
                lvroot /
                lvhome /
                lvswap /

Regards,

Alan

From: laalaa <dbpalan@hotmail.com>
Sent: Thursday, January 26, 2017 12:38:19 PM
To: 852653@bugs.debian.org
Subject: Grub install failed on encrypted LVM disk
 
Dear Maintainer:

Problem solved.  Mark "BOOT" flag in the encrypted disk.  Then grub install completed successfully.

Suggest to verify BOOT flag has been marked to allow proceeding to next installation stage.

Regards,

Alan

#852653#20
Date:
2017-12-12 19:49:06 UTC
From:
To:
I booted using the install disk and used the rescue option

Trying to install grub again from the mounted drive, it reported this
error:
grub-install: warning: Attempting to install GRUB to a disk with
multiple partition labels.  This is not supported yet..
grub-install: warning: Embedding is not possible.  GRUB can only be
installed in this setup by using blocklists.  However, blocklists are
UNRELIABLE and their use is discouraged..
grub-install: error: will not proceed with blocklists.

a quick search yielded this:

https://askubuntu.com/questions/666527/install-grub-claims-that-i-have-multiple-partiton-labels-and-that-embedding-is

The first partition was indeed 2048 so I ran the command as suggested:
dd if=/dev/zero of=/dev/sdX seek=1 count=2047

and then grub successfully installed and it all boots correctly

Not sure if that helps...

#852653#25
Date:
2018-07-20 09:43:59 UTC
From:
To:
Warm Greetings,

I have an intending proposal for you please i need you to contact my private Email :: leiahubert00@gmail.com

for more updates,

Best Wishes.

#852653#30
Date:
2021-02-24 18:37:20 UTC
From:
To:
# User forgot to close it, archiver ignored it due to "critical" tag
close -1