I installed lots of OSs on my PC. The mistake I did was not backing up my EFI partition beforehand.
Now I deleted all the OS except CachyOS (Arch) and Windows.
Now I want to tidy up my EFI partition. I want to delete everything (even rEFInd) except Windows and Default ones like OEM. (I am gonna reinstall CachyOS ) Can anybody please assist me?
I already deleted the obvious ones like ubuntu and fedora. Anything else?
I know this is not necessarily a linux question but anyways 😅
Solved
Before proceeding with any of the following, I STRONGLY suggest you to make a full backup of your ESP (efi) partition.
I deleted everything on boot
folder, since I didn’t need grub or any of those files ( after searching everything individually on internet)
I deleted refind
folder, since I didn’t need refind boot manager.
I kept insyde
folder, since they are my uefi provider.
I kept OEM
, microsoft
folders because I need windows and whatever my OEM provides.
I kept tools
folder since that’s just an empty folder ( I didn’t know which OS created it)
My advice is to leave everything as-is unless you’re running out of space or want to clean it up for fun.
If you want, formatting your efi partition and rebuilding it with bcdboot on Windows will get you to a completely clean setup. This may remove any oem boot options present.
https://learn.microsoft.com/en-us/windows-hardware/manufacture/desktop/bcdboot-command-line-options-techref-di?view=windows-11
If your machine has a factory reset mode you may want to use that instead, although it will probably delete all of your data.
Thank you.