On Tuesday 28 May 2019 19:52:02 Jonathan Billings wrote:
I suggest running 'blkid' and 'efibootmgr -v', and double-check that the UUID for the CentOS boot entry matches the UUID of the EFI disk.
You can delete and recreate the boot entry with 'efibootmgr', which will likely solve the problem.
It depends on the UEFI implementation, but when all the boot entries are wrong (UUID changed due to new disk) sometimes it has a fallback to find the Windows bootloader and choose it.
Thanks Jonathan.
You're probably right about this as whever I try to do makes has effect.
I've been looking in to efibootmgr to see what I need to do to get it working but so far with no luck.
When I run it with -v I don't see any UUID details, nor can i see how I specify them. One thing I have noticed is that in the blkid output below everything refers to HD(2,...... Is that correct?
Below is one of many attempts to set the values correctly.
[root@gary ~]# efibootmgr -v BootCurrent: 0004 Timeout: 0 seconds BootOrder: 0002,3002,0000,0003,0004,0005,2001,2002,2003 Boot0000* Linux HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\centos\shim.efi) Boot0002* Windows Boot Manager HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\Microsoft\Boot\bootmgfw.efi)WINDOWS.........x...B.C.D.O.B.J.E.C.T.=.{.9.d.e.a.8.6.2.c.-.5.c.d.d.-.4.e.7.0.-.a.c.c.1.-.f.3.2.b.3.4.4.d.4.7.9.5.}.................... Boot0003* Fedora HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\fedora\shim.efi) Boot0004* CentOS Linux HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\centos\shim.efi) Boot0005* CentOS HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\centos\shimx64.efi) Boot2001* USB Drive (UEFI) RC Boot2002* Internal CD/DVD ROM Drive (UEFI) RC Boot3000* Internal Hard Disk or Solid State Disk RC Boot3002* Internal Hard Disk or Solid State Disk RC [root@gary ~]# efibootmgr -o 4,2001,2002,2 BootCurrent: 0004 Timeout: 0 seconds BootOrder: 0004,2001,2002,0002 Boot0000* Linux Boot0002* Windows Boot Manager Boot0003* Fedora Boot0004* CentOS Linux Boot0005* CentOS Boot2001* USB Drive (UEFI) Boot2002* Internal CD/DVD ROM Drive (UEFI) Boot3000* Internal Hard Disk or Solid State Disk Boot3002* Internal Hard Disk or Solid State Disk [root@gary ~]# efibootmgr -v BootCurrent: 0004 Timeout: 0 seconds BootOrder: 0004,2001,2002,0002 Boot0000* Linux HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\centos\shim.efi) Boot0002* Windows Boot Manager HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\Microsoft\Boot\bootmgfw.efi)WINDOWS.........x...B.C.D.O.B.J.E.C.T.=.{.9.d.e.a.8.6.2.c.-.5.c.d.d.-.4.e.7.0.-.a.c.c.1.-.f.3.2.b.3.4.4.d.4.7.9.5.}.................... Boot0003* Fedora HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\fedora\shim.efi) Boot0004* CentOS Linux HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\centos\shim.efi) Boot0005* CentOS HD(2,GPT,14c4ac1d-abd8-4121-84ee-c05a825920de,0x145800,0x64000)/File(\EFI\centos\shimx64.efi) Boot2001* USB Drive (UEFI) RC Boot2002* Internal CD/DVD ROM Drive (UEFI) RC Boot3000* Internal Hard Disk or Solid State Disk RC Boot3002* Internal Hard Disk or Solid State Disk RC [root@gary ~]# blkid /dev/mapper/centos-root: UUID="08c18076-37b4-4f65-b550-e2633ac24d5d" TYPE="xfs" /dev/sda6: UUID="ifEKlz-O4SM-NevI-X4TQ-lQg2-0lAN-Jb7cZQ" TYPE="LVM2_member" PARTUUID="97e93e7c-a6cf-4532-8f7d-5c0e50987350" /dev/sda1: LABEL="WINRE" UUID="8262E42362E41DA3" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="277e20d2-ee46-412b-babb-9b2249324ca4" /dev/sda2: SEC_TYPE="msdos" UUID="1437-B8F4" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="14c4ac1d-abd8-4121-84ee-c05a825920de" /dev/sda3: LABEL="Windows" UUID="1098EFF798EFD96C" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="f7cefd8f-73e7-4956-bb96-0c03ea21bff9" /dev/sda4: UUID="12DC737EDC735B45" TYPE="ntfs" PARTUUID="95f8994c-a8ad-48f5-9fbb-eda67c56f6e3" /dev/sda5: UUID="de45b7f8-d072-4f7e-b9be-a62428db3fbb" TYPE="xfs" PARTUUID="8c00cc67-1063-4889-bdce-6f6259ba1491" /dev/sda8: LABEL="RECOVERY" UUID="74CCE22FCCE1EAF6" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="7c95ff6d-d945-4479-9100-f66aa81a403e" /dev/mapper/centos-swap: UUID="30ca7d38-a0df-4473-a1d0-dc7a1fd41458" TYPE="swap" /dev/mapper/centos-home: UUID="abcedda1-b69b-441e-bced-23a66b2b85f6" TYPE="xfs" [root@gary ~]# df Filesystem 1K-blocks Used Available Use% Mounted on /dev/mapper/centos-root 52403200 7424692 44978508 15% / devtmpfs 6016292 0 6016292 0% /dev tmpfs 6034084 0 6034084 0% /dev/shm tmpfs 6034084 9820 6024264 1% /run tmpfs 6034084 0 6034084 0% /sys/fs/cgroup /dev/sda5 1038336 229176 809160 23% /boot /dev/sda2 204576 85252 119324 42% /boot/efi /dev/mapper/centos-home 688017172 428947768 259069404 63% /home tmpfs 1206820 8 1206812 1% /run/user/42 tmpfs 1206820 0 1206820 0% /run/user/0 [root@gary ~]#