I installed Ubuntu multiple times on my computer, and every time I did that I reinstalled GRUB. Does this mean that I have multiple copies of GRUB taking up space? If so, how should I safely remove the excess copies?

If this helps at all:

elementary@elementary:~$ grub --version
The program 'grub' is currently not installed.  You can install it by typing:
sudo apt-get install grub
elementary@elementary:~$ grub-mkconfig --version
grub-mkconfig (GRUB) 1.99-21ubuntu3.10

Does this mean that I have multiple copies of GRUB taking up space?

No, grub installs most of itself into the root filesystem partition (see subdirectories of /boot), so if by "installing multiple times" you mean overwriting one install after another, that's all overwritten too. EFI/GPT systems use some extra hidden space, but that will also always get overwritten (there won't be more than one such space on the drive).

Just to be clear: if you only have one existing linux on the machine, stop reading now.

However, if you mean you have multiple parallel installs on separate existing partitions, then they do all have separate copies, even though only the last one installed is used (make sure you are certain about which one, obviously). It is probably okay to delete the unused ones. An easy test would be to move the grub2 and efi subdirectories in /boot temporarily to a separate partition and then try to boot that system.

how should I safely remove the excess copies?

Use the distro package manager, there should be nothing that depends on it although it may be in separate pieces (grub, grub-efi, grub-tools, grub-themes). If you don't use the package manager, it may end up coming back as an upgrade later. Keep in mind the total size is at most only a dozen MB or so and generally not worth bothering about. Also, I can't promise that some package managers won't do something stupid with the boot sector of the drive (although that would be pretty stupid indeed).

| improve this answer | |

You most likely have five packages installed in each of the isntallations of Ubuntu:


That is however minor space compared to what a single kernels of each these installations requires. (IIRC the last of those packages is an almost empty stub)

In your MBR there is a pointer to the files one of these installations, and that installation scans the other partitions, find kernels and puts them in the grub menu. So in principle you don't need the other grubs, but the total amount of disc space taken by those packages is less than 10Mb, so why bother?

That grub is not installed is because the legacy grub is not installed ( you are currently using grub2)

| improve this answer | |

If you're asking if you have multiple copies of the bootloader code, the answer is no. The boot loader installs its code at the start of the harddrive (the empty space between the partition table and the first partition), and will overwrite anything that was already there.

Now, that is for MBR configurations. If you have UEFI bios and it installed multiple menu entries, then I'm not enough of an expert to answer... You need some sort of UEFI nvram editor.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.