0

I ran out of space for my Ubuntu OS and decided to extend it by unallocating space from Windows OS partition and assigning it to Ubuntu. Ubuntu worked right afterwards but Windows won't boot up. Windows ran its own file check and "fixed" files, and booted up but now Ubuntu is not booting up. Now, when I want to boot Ubuntu, it's not GNU/Linux and just black screen.

I used a live USB Stick with Boot-Repair to fix things and it suggested to purge GRUB and reinstall it. I had issues with that and did everything I could. For example, I had problems with packages and I just manually was "fixing" them (?). But now, it just says grub-efi purge is cancelled. I think I really broken things. I did my own research, and the solutions are very closely connected with EFI partitions and changing things there and I'm kind of scared to do that right now.

Boot-Repair Boot Info Summary:

============================== Boot Info Summary ===============================

=> No boot loader is installed in the MBR of /dev/nvme0n1. => No known boot loader is installed in the MBR of /dev/sda.

nvme0n1p1: _____________________________________________________________________

File system:       vfat
Boot sector type:  Windows 8/10/11/2012: FAT32
Boot sector info:  No errors found in the Boot Parameter Block.
Operating System:  
Boot files:        

nvme0n1p2: _____________________________________________________________________

File system:       
Boot sector type:  -
Boot sector info: 

nvme0n1p3: _____________________________________________________________________

File system:       ntfs
Boot sector type:  Windows 8/10/11/2012: NTFS
Boot sector info:  No errors found in the Boot Parameter Block.
Operating System:  Windows 10 or 11
Boot files:        

nvme0n1p4: _____________________________________________________________________

File system:       ntfs
Boot sector type:  Windows 8/10/11/2012: NTFS
Boot sector info:  No errors found in the Boot Parameter Block.
Operating System:  
Boot files:        

nvme0n1p5: _____________________________________________________________________

File system:       ext4
Boot sector type:  -
Boot sector info: 
Operating System:  Ubuntu 22.04.3 LTS
Boot files:        /boot/grub/grub.cfg /etc/fstab /etc/default/grub

sda1: __________________________________________________________________________

File system:       vfat
Boot sector type:  Windows 8/10/11/2012: FAT32
Boot sector info:  No errors found in the Boot Parameter Block.
Operating System:  
Boot files:        /boot/grub/grub.cfg /efi/boot/bootx64.efi 
                   /efi/boot/grubx64.efi /efi/boot/mmx64.efi

================================ 2 OS detected =================================

OS#1: Ubuntu 22.04.3 LTS on nvme0n1p5 OS#2: Windows 10 or 11 on nvme0n1p3

================================ Host/Hardware =================================

CPU architecture: 64-bit Video: GA107M [GeForce RTX 3050 Mobile] TigerLake-H GT1 [UHD Graphics] from NVIDIA Corporation Intel Corporation Live-session OS is Ubuntu 64-bit (Ubuntu 22.04.3 LTS, jammy, x86_64)

===================================== UEFI =====================================

BIOS/UEFI firmware: V1.18(1.18) from Insyde Corp. The firmware is EFI-compatible, and is set in EFI-mode for this live-session. No EFI in dmseg. SecureBoot disabled (confirmed by mokutil). BootCurrent: 0000 Timeout: 0 seconds BootOrder: 0000,0001,0002,2001,2002,2003 Boot0000* Linpus lite HD(1,GPT,d890c60c-56a1-4c95-8377-d22b508a032e,0x800,0x39bb7e0)/File(\EFI\Boot\grubx64.efi)RC Boot0001* Windows Boot Manager HD(1,GPT,f9395298-f076-48ab-9d99-76af71f5c8f1,0x800,0x32000)/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.}.................... Boot0002* ubuntu HD(1,GPT,f9395298-f076-48ab-9d99-76af71f5c8f1,0x800,0x32000)/File(\EFI\ubuntu\shimx64.efi) Boot2001* EFI USB Device RC Boot2002* EFI DVD/CDROM RC Boot2003* EFI Network RC

============================= Drive/Partition Info =============================

Disks info: ____________________________________________________________________

nvme0n1 : is-GPT, no-BIOSboot, has---ESP, not-usb, not-mmc, has-os, has-win, 2048 sectors * 512 bytes

Partitions info (1/3): _________________________________________________________

nvme0n1p1 : no-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, not-far nvme0n1p3 : is-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, farbios nvme0n1p4 : no-os, 64, nopakmgr, no-docgrub, nogrub, nogrubinstall, no-grubenv, noupdategrub, farbios nvme0n1p5 : is-os, 64, apt-get, signed grub-pc grub-efi , grub2, grub-install, grubenv-ng, update-grub, farbios

Partitions info (2/3): _________________________________________________________

nvme0n1p1 : is---ESP, part-has-no-fstab, no-nt, no-winload, no-recov-nor-hid, no-bmgr, notwinboot nvme0n1p3 : isnotESP, part-has-no-fstab, no-nt, haswinload, no-recov-nor-hid, no-bmgr, notwinboot nvme0n1p4 : isnotESP, part-has-no-fstab, no-nt, no-winload, recovery-or-hidden, no-bmgr, notwinboot nvme0n1p5 : isnotESP, fstab-has-goodEFI, no-nt, no-winload, no-recov-nor-hid, no-bmgr, notwinboot

Partitions info (3/3): _________________________________________________________

nvme0n1p1 : not--sepboot, no---boot, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, nvme0n1 nvme0n1p3 : not--sepboot, no---boot, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, nvme0n1 nvme0n1p4 : not--sepboot, no---boot, part-has-no-fstab, not-sep-usr, no---usr, part-has-no-fstab, no--grub.d, nvme0n1 nvme0n1p5 : not--sepboot, with-boot, fstab-without-boot, not-sep-usr, with--usr, fstab-without-usr, std-grub.d, nvme0n1

fdisk -l (filtered): ___________________________________________________________

Disk nvme0n1: 476.94 GiB, 512110190592 bytes, 1000215216 sectors Disk identifier: 8BECBD3C-43DC-45B2-9BCE-419172A7FA16 Start End Sectors Size Type nvme0n1p1 2048 206847 204800 100M EFI System nvme0n1p2 206848 239615 32768 16M Microsoft reserved nvme0n1p3 239616 862603263 862363648 411.2G Microsoft basic data nvme0n1p4 998420480 1000210431 1789952 874M Windows recovery environment nvme0n1p5 862603264 998420479 135817216 64.8G Linux filesystem Partition table entries are not in disk order. Disk sda: 28.87 GiB, 30995907072 bytes, 60538881 sectors Disk identifier: 7045AE4E-C377-40BC-BF76-917289018D38 Start End Sectors Size Type sda1 2048 60538847 60536800 28.9G Microsoft basic data

parted -lm (filtered): _________________________________________________________

sda:31.0GB:scsi:512:512:gpt:Kingston DataTraveler 3.0:; 1:1049kB:31.0GB:31.0GB:fat32:Main Data Partition:msftdata; nvme0n1:512GB:nvme:512:512:gpt:WDC PC SN530 SDBPNPZ-512G-1114:; 1:1049kB:106MB:105MB:fat32:EFI system partition:boot, esp; 2:106MB:123MB:16.8MB::Microsoft reserved partition:msftres; 3:123MB:442GB:442GB:ntfs:Basic data partition:msftdata; 5:442GB:511GB:69.5GB:ext4::; 4:511GB:512GB:916MB:ntfs::hidden, diag;

blkid (filtered): ______________________________________________________________

NAME FSTYPE UUID PARTUUID LABEL PARTLABEL sda
└─sda1 vfat B6BD-2780 d890c60c-56a1-4c95-8377-d22b508a032e UBUNTU 22_0 Main Data Partition nvme0n1
├─nvme0n1p1 vfat FEAB-FFD7 f9395298-f076-48ab-9d99-76af71f5c8f1 EFI system partition ├─nvme0n1p2 87545613-096d-40e8-b3a7-aedaaf5de1fc Microsoft reserved partition ├─nvme0n1p3 ntfs 020CB7520CB73F89 141a3195-2de2-4709-9ceb-9d28505a636e Basic data partition ├─nvme0n1p4 ntfs 424AB0C34AB0B4CF 0cc59d7c-896c-4023-ae10-1ca6b68a498e
└─nvme0n1p5 ext4 9e5a9876-5906-4a22-b0ef-6b0c527bde57 0a780072-4375-4fdd-9863-73ce29f81570

Mount points (filtered): _______________________________________________________ Avail Use% Mounted on /dev/nvme0n1p4 76.1M 91% /mnt/boot-sav/nvme0n1p4 /dev/nvme0n1p5 29.8G 48% /mnt /dev/sda1 24.2G 16% /cdrom

Mount options (filtered): ______________________________________________________

=================== nvme0n1p5/boot/grub/grub.cfg (filtered) ====================

GNU/Linux 9e5a9876-5906-4a22-b0ef-6b0c527bde57 GNU/Linux, with Linux 6.2.0-35-generic 9e5a9876-5906-4a22-b0ef-6b0c527bde57 GNU/Linux, with Linux 6.2.0-34-generic 9e5a9876-5906-4a22-b0ef-6b0c527bde57 Windows Boot Manager (on nvme0n1p1) osprober-efi-FEAB-FFD7

END /etc/grub.d/30_os-prober

END /etc/grub.d/30_uefi-firmware

======================== nvme0n1p5/etc/fstab (filtered) ========================

<file system> <mount point> <type> <options> <dump> <pass>

/ was on /dev/nvme0n1p5 during installation

UUID=9e5a9876-5906-4a22-b0ef-6b0c527bde57 / ext4 errors=remount-ro 0 1

/boot/efi was on /dev/nvme0n1p1 during installation

UUID=FEAB-FFD7 /boot/efi vfat umask=0077 0 1 /swapfile none swap sw 0 0

==================== nvme0n1p5/etc/default/grub (filtered) =====================

GRUB_DISABLE_OS_PROBER=false GRUB_DISABLE_OS_PROBER=false GRUB_DISABLE_OS_PROBER=false GRUB_DISABLE_OS_PROBER=false

================= nvme0n1p5: Location of files loaded by Grub ==================

       GiB - GB             File                                 Fragment(s)

440.186527252 = 472.646684672 boot/grub/grub.cfg 1 413.935695648 = 444.460068864 boot/vmlinuz 1 437.938472748 = 470.232854528 boot/vmlinuz-6.2.0-34-generic 2 413.935695648 = 444.460068864 boot/vmlinuz-6.2.0-35-generic 1 437.938472748 = 470.232854528 boot/vmlinuz.old 2 433.646598816 = 465.624489984 boot/initrd.img 70 444.735122681 = 477.530701824 boot/initrd.img-6.2.0-34-generic 203 433.646598816 = 465.624489984 boot/initrd.img-6.2.0-35-generic 70 444.735122681 = 477.530701824 boot/initrd.img.old 203

=================== nvme0n1p5: ls -l /etc/grub.d/ (filtered) ===================

-rwxr-xr-x 1 root root 18683 Dec 18 2022 10_linux -rwxr-xr-x 1 root root 43031 Dec 18 2022 10_linux_zfs -rwxr-xr-x 1 root root 14387 Dec 18 2022 20_linux_xen -rwxr-xr-x 1 root root 13369 Dec 18 2022 30_os-prober -rwxr-xr-x 1 root root 1372 Dec 18 2022 30_uefi-firmware -rwxr-xr-x 1 root root 700 May 17 05:35 35_fwupd -rwxr-xr-x 1 root root 214 Dec 18 2022 40_custom -rwxr-xr-x 1 root root 215 Dec 18 2022 41_custom

====================== sda1/boot/grub/grub.cfg (filtered) ======================

Try or Install Ubuntu Ubuntu (safe graphics) OEM install (for manufacturers) Boot from next volume UEFI Firmware Settings Test memory

==================== sda1: Location of files loaded by Grub ====================

       GiB - GB             File                                 Fragment(s)
        ?? = ??             boot/grub/grub.cfg                             1

Suggested repair: ______________________________________________________________

The default repair of the Boot-Repair utility will purge (in order to unsign) and reinstall the grub-efi of nvme0n1p5, using the following options: nvme0n1p1/boot/efi Additional repair will be performed: unhide-bootmenu-10s use-standard-efi-file restore-efi-backups

Final advice in case of suggested repair: ______________________________________

Please do not forget to make your UEFI firmware boot on the Ubuntu 22.04.3 LTS entry (nvme0n1p1/efi/**/grub.efi (** will be updated in the final message) file) ! If your computer reboots directly into Windows, try to change the boot order in your UEFI firmware. If your UEFI firmware does not allow to change the boot order, change the default boot entry of the Windows bootloader. For example you can boot into Windows, then type the following command in an admin command prompt: bcdedit /set {bootmgr} path \EFI**\grub.efi (** will be updated in the final message)

paste.ubuntu.com ko () paste.debian.net ko (https://paste.debian.net/)

karel
  • 114,770
illy
  • 1
  • Report shows p1 as ESP, FAT32, but is not showing the /efi boot files that it should show. I might run chkdsk if using Windows or dosfsck from Ubuntu. sudo fsck.vfat -t -a /dev/nvme0n1pY # where Y is ESP partition. https://askubuntu.com/questions/862724/grub2-failed-to-install/86587z682#865872 See also man dosfsck – oldfred Oct 31 '23 at 16:58
  • I ran chkdsk on Windows and it said that everything is fine. I ran sudo fsck.vfat -t -a /dev/nvme0n1p1 and it said: fsck.fat 4.2 (2021-01-31) /dev/nvme0n1p1: 208 files, 37566/98304 clusters. Before that it also said something about setting up or fixing a dirty bit. I tried boot-repair again and it still showed grub-efi purge cancelled. So I decided to mount p1 to check /efi/Boot which has bootx64.efi fbx64.efi mmx64.efi. Then /efi/grub has BOOTX64.CSV grub.cfg grubx64.efi mmx64.efi shimx64.efi. And /efi/ubuntu has BOOTX64.CSV grub.cfg grubx64.efi mmx64.efi shimx64.efi. – illy Nov 02 '23 at 12:25
  • Then I decided to check p5 where my ubuntu is. I checked what's inside /boot/grub and there was: fonts gfxblacklist.txt grub.cfg grubenv locale unicode.pf2 x86_64-efi. Then I checked what's inside /boot/efi and there is nothing there, so I think maybe that's the problem (?) – illy Nov 02 '23 at 12:27
  • From live installer, your Ubuntu partition will not have /boot/efi as the ESP has not been mounted by fstab as part of boot. If you have boot files in ESP & an UEFI entry, does that work? – oldfred Nov 02 '23 at 17:58
  • I don't get what you mean. Should I just reinstall Ubuntu? I have a backup, just will need to pull some things from github – illy Nov 04 '23 at 06:02
  • Report does not show normal: nvme0n1p5/etc/default/grub just the os=prober entry? And UEFI boot order shows Linpus Lite as default? You can try a full chroot and purge & reinstall grub from inside that. UEFI chroot, must include ESP - efi system partition http://askubuntu.com/questions/53578/can-i-install-in-uefi-mode-with-the-alternate-installer/57380#57380 – oldfred Nov 04 '23 at 13:28

0 Answers0