0

So, I had Ubuntu dual boot. I removed Ubuntu's Swap and root partition but I still think grub exists in my PC because on startup it comes up. Right now I'm booting directly to windows ssd via boot priority but still want to clean grub but I also don't want to remove my windows boot partition so I'm scared to remove any other EFI partition because I don't know which one is a grub and which one window boot

2 TB hard disk is not grub. Grub is on my 500GB SSD because that is what I used for Ubuntu. Help me remove grub enter image description here

1

2 Answers 2

1

I'm scared to remove any other EFI partition because I don't know which one is a grub and which one window boot

Based on your screenshots, you only have one EFI partition in the first place.

Quite possible that either a) you already removed the Ubuntu one, or b) both Windows and Ubuntu are using the same EFI partition.

The EFI partition is just a regular FAT32 partition holding regular files, so uninstalling GRUB basically means deleting the files that were installed by GRUB (grubx64.efi, grub.cfg).

  1. Use mountvol S: /s to assign a disk letter to the EFI partition.
  2. Use commands such as dir S:\, dir S:\EFI\, etc. to look at what files are stored in that partition. Windows files will always be in \EFI\Microsoft, whereas Ubuntu might have installed GRUB into \EFI\Ubuntu or \EFI\Grub.
  3. Delete the GRUB files.

However, deleting the files will not remove the EFI boot menu entry, nor the other way around. EFI boot entries are stored in the motherboard's NVRAM and managed using special tools, such as efibootmgr on Linux or bcdedit on Windows. (The latter is a confusing dual-purpose tool that simultaneously manages EFI entries and Windows BOOTMGR entries.)

  1. Use bcdedit /enum firmware to list all EFI boot entries. The command will show their identifiers that you'll need to use later for deletion, as well as which partition and which file they point to.

  2. If you see an entry named like "Ubuntu" or "GRUB", use bcdedit /delete {the-identifier-here} to remove it.

    Note: Many motherboards will also list virtual entries named "Firmware Application" or such. Do not try to delete those.


(If you actually had two EFI partitions, this other thread is about figuring out which partition is used by what OS.)

3
  • No just one EFI partition. I cleaned one root and one 4gb swap. No other partition besides that. I think windows and Linux using this same EFI one Commented Nov 11, 2020 at 13:55
  • dir S:\EFI\ shows me Microsoft, Boot, ubuntu. How do delete ubuntu? del S:\EFI\ubuntu? That's it? Commented Nov 12, 2020 at 23:40
  • It's a directory, so to delete it fully (with its contents) you need del -recurse in Powershell or rd/s in Cmd. (You can also use various third-party file manager apps -- the regular Windows Explorer won't work, but e.g. Total Commander or Far Manager should be able to access S: just fine.) Commented Nov 13, 2020 at 9:12
0

You can find out where grub (grub2) is installed using the command:

sudo grub-probe -t device /boot/grub

This information you can find out at: grub2 setup

1
  • Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.
    – Community Bot
    Commented Jun 6 at 6:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .