GRUB not loading after CentOS update in a Windows 10 dual boot setup

I searched the interwebs and I'm basically having the same issue as this guy but there's no solution.

I installed CentOS on an HP computer with UEFI enabled and everything was going swimmingly. I was able to restart and select which OS I wanted to boot.

I installed the CentOS updates and got this error message

Shim was unable to measure state into the TPM    

before the computer shuts down. I was still able to bring up the BIOS boot menu and select Windows but Linux was dead.

I have since reformatted the hard drive and installed Windows but I want to install CentOS again. Hoping to get ways to fix this issue

Posted Dec 20, 2018, 7:29 AM UTC

113
diabonas•

This is an issue with the shim boot loader, which is loaded before GRUB in order to be able to use Secure Boot and to verify that the boot process has not been tampered with. To do this, a Trusted Platform Module (TPM) is used if available, which seems to fail on your system.

This first thing I would try to diagnose the problem is to check whether you can disable the TPM: many mainboards offer a BIOS setting to this effect, look out for something called "TPM 1.2"/"TPM 2.0"/"fTPM", ... For the linked StackExchange post, disabling the TPM should fix the problem because judging from the source code, the error "Unable to trigger tcg2 final events table" can only occur if a TPM 2.0 device is found on the system. Do you also get some additional errors on your system before "Shim was unable to measure state into the TPM", or is this the only message you are seeing?

Note that you shouldn't disable the TPM if you are using BitLocker for your Windows partition, because Windows stores the encryption keys on the TPM by default!

From a quick web search, you are not alone with the problem, there is even a bug report for CentOS (which also advises to disable the TPM as a hotfix). Judging from a corresponding RHEL bug report linked there, an updated version of shim might fix the problem, but I don't know when this update will be available for CentOS.

If disabling the TPM is not possible or doesn't fix the problem, you might want to try a different boot loader: if you disable Secure Boot (again, there should be a BIOS setting for that), you can use GRUB directly without loading shim first (or install any other boot loader you like).

4
The_sys_admin•

i think u could've used a live usb with unix, then mount the drives and then chroot and reinstall grub. im not that good with unix yet so don't take my word for it :)

2
paradox_guy420•

Install A grub separately

2