2

I had tried in vain to install Debian (which didn't work) and after that I have installed Ubuntu with LVM. Now I still have the boot entry for both OS (F7 key on startup). Both OSes were installed by using LVM-encryption and encryption.

As suggested I installed grub-customizer, which looks like this:

enter image description here

No mention of Debian there. How can I get rid of this entry?

Output of efibootmgr:

nuc@nuc:~$ sudo efibootmgr
[sudo] Passwort für nuc: 
BootCurrent: 0001
Timeout: 1 seconds
BootOrder: 0001,0004,0002,0003
Boot0001* ubuntu
Boot0002* UEFI: PXE IPv4 Intel(R) Ethernet Connection (10) I219-V
Boot0003* UEFI: PXE IPv6 Intel(R) Ethernet Connection (10) I219-V
Boot0004* debian
MarianD
  • 1,028
yaimo
  • 23
  • Do you really to format the disk? You could simply install grub-customizer (sudo apt install grub-customizer) and from there deleting unwanted entries. If not, please edit your question with the reason and the current situation. – dariofac Dec 22 '20 at 09:43
  • Can I reinstall Ubuntu LTS this way as well if the current Ubuntu is encryptet? And isn't there anything left on the harddrive of Debian (it was an encrypted installation). – yaimo Dec 22 '20 at 09:47
  • My previous comment was useful only in case you want to get rid of Debian boot entry (it does not delete anything on disk). If you installed Ubuntu "over" Debian on the same partition, you can just delete such entry. But to be sure, we need to have a clearer idea on how your disk is partitioned – dariofac Dec 22 '20 at 09:51
  • Can you help me to find out? I'm not sure if Ubuntu could recocnize Debian (if it was encrypteted I even if I intended to install it on the same harddrive and formated the disk during install). – yaimo Dec 22 '20 at 10:09
  • You have first to tell us the history of your action. When you say "and after that I have installed Ubuntu", can you be more specific on how you performed it? – dariofac Dec 22 '20 at 10:22
  • Does this answer your question? How do I install Ubuntu? – dariofac Dec 22 '20 at 10:25
  • I performed it over an USB iso stick by using LVM encription (both with debian and later with ubuntu). – yaimo Dec 22 '20 at 10:25
  • As I have to reinstall ubuntu anyway formatting the whole thing might be faster. – yaimo Dec 22 '20 at 10:26
  • Because Ubuntu seems also broken (I can't access the settings anymore, it shows the hourglass for ages). – yaimo Dec 22 '20 at 10:29
  • I think you talk about efi boot menu entries, this answer might be helpful. – mook765 Dec 22 '20 at 10:30
  • @dariofac: I updated the question with a screenshot of grub-customizer. – yaimo Dec 22 '20 at 11:40
  • In the screenshot there is no reference of Debian to me.. As suggested by @mook765, please post also the output of sudo efibootmgr – dariofac Dec 22 '20 at 12:05
  • @dariofac: Posted it, it's the last entry. – yaimo Dec 22 '20 at 13:16

1 Answers1

3

According to the information acquired in the comments, you only want to remove the Debian entry from the UEFI boot menu. To do that:

Open a terminal and run:

sudo efibootmgr

The output will be, as stated in the question, like this:

BootCurrent: 0001
Timeout: 1 seconds
BootOrder: 0001,0004,0002,0003
Boot0001* ubuntu
Boot0002* UEFI: PXE IPv4 Intel(R) Ethernet Connection (10) I219-V
Boot0003* UEFI: PXE IPv6 Intel(R) Ethernet Connection (10) I219-V
Boot0004* debian

To remove the unwanted entry (debian in this case), run:

sudo efibootmgr -b 4 -B

which will delete the following entry: Boot0004* debian.

After that, remove the debian folder from the EFI partition by running:

sudo rm -r /boot/efi/EFI/debian

Since grub doesn't seem to have references to debian, the process stops here.

At the reboot you shouldn't see debian anymore.

Thanks to this answer and mook765.

dariofac
  • 1,042
  • Thanks. Can I find out if there is still something of Debian or other ubuntuinstallations left on my harddrive if I used encryptions? – yaimo Dec 22 '20 at 13:40