Remove ghost kernel from /boot and GRUB

I have the following outputs:

❯ sudo mhwd-kernel -li
Currently running: 6.1.23-1-MANJARO (linux61)
The following kernels are installed in your system:
   * linux61
   * linux62
❯ pacman -Q | grep "^linux"
linux-api-headers 6.1.9-1
linux-firmware 20230310.588dd07-1
linux-firmware-whence 20230310.588dd07-1
linux61 6.1.23-1
linux61-virtualbox-host-modules 7.0.6-21
linux62 6.2.10-1
linux62-virtualbox-host-modules 7.0.6-12

so far, everything ok. but on the other hand :

   ❯ ls -l /boot
drwx------     - root  1 Jan  1970  efi
drwxr-xr-x     - root 11 Apr 11:33  grub
drwxr-xr-x     - root 12 Feb 11:23  memtest86+
.rw-r--r--   51k root  1 Apr 05:39  amd-ucode.img
.rw-------   37M root 16 Jun  2022  initramfs-5.18-rt-x86_64-fallback.img
.rw-------  8,5M root 16 Jun  2022  initramfs-5.18-rt-x86_64.img
.rw-------   38M root 11 Apr 11:17  initramfs-6.1-x86_64-fallback.img
.rw-------  9,1M root 11 Apr 11:17  initramfs-6.1-x86_64.img
.rw-------   40M root 11 Apr 11:33  initramfs-6.2-x86_64-fallback.img
.rw-------  9,2M root 11 Apr 11:33  initramfs-6.2-x86_64.img
.rw-r--r--    21 root  6 Apr 19:13  linux61-x86_64.kver
.rw-r--r--    21 root  6 Apr 19:12  linux62-x86_64.kver
.rw-r--r--    21 root 22 Dez  2020  linux510-x86_64.kver.old
.rw-r--r-- 10,0M root 16 Jun  2022  vmlinuz-5.18-rt-x86_64
.rw-r--r--   11M root 11 Apr 10:44  vmlinuz-6.1-x86_64
.rw-r--r--   13M root 11 Apr 11:33  vmlinuz-6.2-x86_64

These entries are also present in the GRUB!
Then I deleted as described in How to remove a “ghost-kernel”? these files!


/boot🔒 
❯ sudo rm initramfs-5.18-rt-x86_64.img 
[sudo] Passwort für wael: 

/boot🔒 took 3s 
❯ sudo rm initramfs-5.18-rt-x86_64-fallback.img 

/boot🔒 
❯ sudo rm vmlinuz-5.18-rt-x86_64 


/etc🔒 
❯  cd /etc/mkinitcpio.d

/etc/mkinitcpio.d🔒 
❯ sudo rm linux54.preset.pacsave linux58.preset.pacsave linux59.preset.pacsave linux510.preset.pacsave linux511.preset.pacsave 

/etc/mkinitcpio.d🔒 
❯ sudo rm linux512.preset.pacsave linux514.preset.pacsave linux515.preset.pacsave 

/etc/mkinitcpio.d🔒 
❯ sudo rm linux515-rt.preset.pacsave linux516.preset.pacsave  linux517.preset.pacsave linux518.preset.pacsave 

/etc/mkinitcpio.d🔒 
❯ sudo rm linux518-rt.preset linux519.preset.pacsave 

/etc/mkinitcpio.d🔒 
❯ sudo rm linux60.preset 

/etc/mkinitcpio.d🔒 
❯ sudo pacman -Qs linux518-

/etc/mkinitcpio.d🔒 
❯ sudo pacman -Qs linux515-

/etc/mkinitcpio.d🔒 
❯ sudo mkinitcpio -P
==> Building image from preset: /etc/mkinitcpio.d/linux61.preset: 'default'
  -> -k /boot/vmlinuz-6.1-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-6.1-x86_64.img --microcode /boot/amd-ucode.img
==> Starting build: '6.1.23-1-MANJARO'
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [autodetect]
  -> Running build hook: [modconf]
  -> Running build hook: [block]
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
  -> Running build hook: [resume]
  -> Running build hook: [keyboard]
  -> Running build hook: [keymap]
  -> Running build hook: [filesystems]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: '/boot/initramfs-6.1-x86_64.img'
==> Image generation successful
==> Building image from preset: /etc/mkinitcpio.d/linux61.preset: 'fallback'
  -> -k /boot/vmlinuz-6.1-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-6.1-x86_64-fallback.img -S autodetect --microcode /boot/amd-ucode.img
==> Starting build: '6.1.23-1-MANJARO'
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [modconf]
  -> Running build hook: [block]
==> WARNING: Possibly missing firmware for module: 'qed'
==> WARNING: Possibly missing firmware for module: 'bfa'
==> WARNING: Possibly missing firmware for module: 'qla1280'
==> WARNING: Possibly missing firmware for module: 'qla2xxx'
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
  -> Running build hook: [resume]
  -> Running build hook: [keyboard]
  -> Running build hook: [keymap]
  -> Running build hook: [filesystems]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: '/boot/initramfs-6.1-x86_64-fallback.img'
==> Image generation successful
==> Building image from preset: /etc/mkinitcpio.d/linux62.preset: 'default'
  -> -k /boot/vmlinuz-6.2-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-6.2-x86_64.img --microcode /boot/amd-ucode.img
==> Starting build: '6.2.10-1-MANJARO'
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [autodetect]
  -> Running build hook: [modconf]
  -> Running build hook: [block]
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
  -> Running build hook: [resume]
  -> Running build hook: [keyboard]
  -> Running build hook: [keymap]
  -> Running build hook: [filesystems]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: '/boot/initramfs-6.2-x86_64.img'
==> Image generation successful
==> Building image from preset: /etc/mkinitcpio.d/linux62.preset: 'fallback'
  -> -k /boot/vmlinuz-6.2-x86_64 -c /etc/mkinitcpio.conf -g /boot/initramfs-6.2-x86_64-fallback.img -S autodetect --microcode /boot/amd-ucode.img
==> Starting build: '6.2.10-1-MANJARO'
  -> Running build hook: [base]
  -> Running build hook: [udev]
  -> Running build hook: [modconf]
  -> Running build hook: [block]
==> WARNING: Possibly missing firmware for module: 'qed'
==> WARNING: Possibly missing firmware for module: 'bfa'
==> WARNING: Possibly missing firmware for module: 'qla1280'
==> WARNING: Possibly missing firmware for module: 'qla2xxx'
==> WARNING: Possibly missing firmware for module: 'xhci_pci'
  -> Running build hook: [resume]
  -> Running build hook: [keyboard]
  -> Running build hook: [keymap]
  -> Running build hook: [filesystems]
==> Generating module dependencies
==> Creating gzip-compressed initcpio image: '/boot/initramfs-6.2-x86_64-fallback.img'
==> Image generation successful

/etc/mkinitcpio.d🔒 took 28s 
❯ sudo update-grub
GRUB-Konfigurationsdatei wird erstellt …
Thema gefunden: /usr/share/grub/themes/manjaro/theme.txt
Linux-Abbild gefunden: /boot/vmlinuz-6.2-x86_64
initrd-Abbild gefunden: /boot/amd-ucode.img /boot/initramfs-6.2-x86_64.img
Found initrd fallback image: /boot/initramfs-6.2-x86_64-fallback.img
Linux-Abbild gefunden: /boot/vmlinuz-6.1-x86_64
initrd-Abbild gefunden: /boot/amd-ucode.img /boot/initramfs-6.1-x86_64.img
Found initrd fallback image: /boot/initramfs-6.1-x86_64-fallback.img
/etc/grub.d/bin/grubcfg_proxy: /usr/lib/libcrypto.so.1.1: version `OPENSSL_1_1_0' not found (required by /etc/grub.d/bin/grubcfg_proxy)
/etc/grub.d/proxifiedScripts/linux: Zeile 208: version_find_latest: Kommando nicht gefunden.

/etc/mkinitcpio.d🔒 
❯ 

after a cold start, the GRUB MENU has not changed at all!

Questions:

  1. how can I remove these entries? and what about the error message in ‘update-grub’: (DE → EN)
/etc/grub.d/bin/grubcfg_proxy: /usr/lib/libcrypto.so.1.1: version `OPENSSL_1_1_0' not found (required by /etc/grub.d/bin/grubcfg_proxy)
/etc/grub.d/proxifiedScripts/linux: line 208: version_find_latest: command not found.
  1. a long time ago I installed ‘grub-customizer’ and then uninstalled it again! maybe it’s related?

  2. why is the new kernel 6.2 not used?

Thanks for your help :slight_smile:

PS: I use Manjaro KDE since 2.5 years (my first Ditsro), but this is my first post here.

You don’t say how you installed/uninstalled 5.10 and 5.18.

But somehow there are leftovers from 5.10 and 5.18. (maybe not only in /boot). They are useless now and should be removed. But be careful not to break the current kernel.

Then please also look in /usr/lib/modules :footprints:


Did you stop GRUB at boot to select the other kernel ?


You can also use maxi -eg

to collect information about the boot process. This works,

  • when you are in your running system (with CTRL+ALT+F2).
  • And also in a live environment

You don’t say how you installed/uninstalled 5.10 and 5.18.

it’s been a while… either they were uninstalled automatically or I did it via the GUI.

❯ /usr/lib/modules

/usr/lib/modules🔒 
❯ ls
drwxr-xr-x - root 11 Apr 10:44  6.1.23-1-MANJARO
drwxr-xr-x - root 11 Apr 11:33  6.2.10-1-MANJARO
drwxr-xr-x - root 20 Jan  2021  extramodules-5.10-MANJARO
drwxr-xr-x - root 11 Apr 10:44  extramodules-6.1-MANJARO
drwxr-xr-x - root 11 Apr 11:33  extramodules-6.2-MANJARO

/usr/lib/modules🔒 
❯ cd extramodules-5.10-MANJARO/

lib/modules/extramodules-5.10-MANJARO🔒 
❯ ls
.rw-r--r-- 17 root 22 Dez  2020  version.old

Did you stop GRUB at boot to select the other kernel ?

yes, i can’t see the new Kernel

What files are inside the /etc/mkinitcpio.d/

.pacsave are just backup save files which are safe to delete.

.preset are the kernels that are installed and ready to run from grub.

So delete any .preset files of the kernels you are removing/don’t need then do a ‘mkinitcpio -P’ and ‘update-grub’
Please DO NOT DELETE the .preset file/files for the kernels you need/installed.

❯ ls /etc/mkinitcpio.d/
.rw-r--r-- 588 root 11 Apr 10:44  linux61.preset
.rw-r--r-- 588 root 11 Apr 11:33  linux62.preset

i first need to make sure i can use kernel 6.2! also i would keep kernel 6.1 (LTS)!

Yes keep 6.1 just in case something bad happens,

Did you do

sudo mkinitcpio -P

and then

sudo update-grub

yes, i did. Grub-menu has not changed unfortunately!

For info:
I can use the system normally, I had no problems all the time. but now I want to get rid of these problems.


and why do I have the entries twice !!?? :face_with_raised_eyebrow:

You could try just ‘sudo grub-mkconfig’ and ‘sudo update-grub’ and see if that works.
Not sure, only option i have left is this:

but you need to follow the instructions for either BIOS (old mode) or UEFI,
** IF YOU DO THIS WRONG YOU WILL NOT BE ABLE TO BOOT YOUR SYSTEM **

In my case as i have my bios set to CSM mode (BIOS BOOT/OLD MODE) all i have to do is

sudo grub-install /dev/sda

‘sda’ is the boot drive/mbr drive, you will need to check what your drive name is.

and

sudo grub-mkconfig

You could try just ‘sudo grub-mkconfig’ and ‘sudo update-grub’ and see if that works.

I personally think this :point_up_2:, that @TheReaperUK suggested, would be the way to go…

not sure how to do this with chroot!
I have an EFI system with:

❯ lsblk
NAME         MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTS
nvme0n1      259:2    0 476,9G  0 disk 
├─nvme0n1p1  259:3    0   260M  0 part 
├─nvme0n1p2  259:4    0    16M  0 part 
├─nvme0n1p3  259:5    0   100G  0 part 
├─nvme0n1p4  259:6    0  1000M  0 part 
├─nvme0n1p5  259:7    0   100G  0 part /
├─nvme0n1p6  259:8    0    50G  0 part 
├─nvme0n1p10 259:10   0  67,7G  0 part 
└─nvme0n1p11 259:11   0     8G  0 part [SWAP]

❯ lsblk -o PATH,PTTYPE,PARTTYPE,FSTYPE,PARTTYPENAME
PATH            PTTYPE PARTTYPE                             FSTYPE PARTTYPENAME
/dev/nvme0n1    gpt                                                
/dev/nvme0n1p1  gpt    c12a7328-f81f-11d2-ba4b-00a0c93ec93b vfat   EFI System
/dev/nvme0n1p2  gpt    e3c9e316-0b5c-4db8-817d-f92df00215ae        Microsoft reserved
/dev/nvme0n1p3  gpt    ebd0a0a2-b9e5-4433-87c0-68b6b72699c7 ntfs   Microsoft basic data
/dev/nvme0n1p4  gpt    de94bba4-06d1-4d40-a16a-bfd50179d6ac ntfs   Windows recovery environment
/dev/nvme0n1p5  gpt    0fc63daf-8483-4772-8e79-3d69d8477de4 ext4   Linux filesystem
/dev/nvme0n1p6  gpt    0fc63daf-8483-4772-8e79-3d69d8477de4 ext4   Linux filesystem
/dev/nvme0n1p8  gpt    0fc63daf-8483-4772-8e79-3d69d8477de4 ext4   Linux filesystem
/dev/nvme0n1p10 gpt    0fc63daf-8483-4772-8e79-3d69d8477de4 ext4   Linux filesystem
/dev/nvme0n1p11 gpt    0657fd6d-a4ab-43c4-84e5-0933c84b4f4f swap   Linux swap

  1. shoud i reinstall GRUB:
    pacman -Syu grub

  2. How to bee in chroot for next procedure?

  • Reinstall grub:
grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=manjaro --recheck 
  • Update the grub configuration
grub-mkconfig -o /boot/grub/grub.cfg 

Please be carefull. Its not good to mess up a booting system in trying to repair a problem you do not understand jet. :footprints:

This could indeed be the origin of your issue… Uninstalling does not repair the damage the use of this tool could have caused.

Can’t really help you as your using EFI, but did you try at least doing:

sudo grub-mkconfig

and

sudo update-grub

From terminal?

GRUB update fails so this is why the menu doesn’t change. This is what you need to fix now.

I don’t know what grubcfg_proxy is, probably something you installed. Maybe you’re a user of GRUB Customizer?

yes, several times.

❯ sudo grub-mkconfig
  
[sudo] Passwort für wael: 
GRUB-Konfigurationsdatei wird erstellt …
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
  load_env
fi
if [ "${next_entry}" ] ; then
   set default="${next_entry}"
   set next_entry=
   save_env next_entry
   set boot_once=true
else
   set default="Manjaro Linux"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
  menuentry_id_option="--id"
else
  menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}

function load_video {
  if [ x$feature_all_video_module = xy ]; then
    insmod all_video
  else
    insmod efi_gop
    insmod efi_uga
    insmod ieee1275_fb
    insmod vbe
    insmod vga
    insmod video_bochs
    insmod video_cirrus
  fi
}

set menu_color_normal=light-gray/black
set menu_color_highlight=green/black

if [ x$feature_default_font_path = xy ] ; then
   font=unicode
else
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
    font="/usr/share/grub/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
  set locale_dir=$prefix/locale
  set lang=de_DE
  insmod gettext
fi
terminal_input console
terminal_output gfxterm
Thema gefunden: /usr/share/grub/themes/manjaro/theme.txt
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
insmod gfxmenu
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_14.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_24.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_48.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_bold_16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_mono_12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-14.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-18.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b14.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b18.pf2
insmod png
set theme=($root)/usr/share/grub/themes/manjaro/theme.txt
export theme
if [ x$feature_timeout_style = xy ] ; then
  set timeout_style=hidden
  set timeout=10
# Fallback hidden-timeout code in case the timeout_style feature is
# unavailable.
elif sleep --interruptible 10 ; then
  set timeout=0
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/06_grub-customizer_menu_color_helper ###
### END /etc/grub.d/06_grub-customizer_menu_color_helper ###

### BEGIN /etc/grub.d/10_linux ###
Linux-Abbild gefunden: /boot/vmlinuz-6.2-x86_64
initrd-Abbild gefunden: /boot/amd-ucode.img /boot/initramfs-6.2-x86_64.img
menuentry 'Manjaro Linux' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_gpt
        insmod ext2
        search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
        linux   /boot/vmlinuz-6.2-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw  quiet resume=LABEL=swap apparmor=1 security=apparmor udev.log_priority=3
        initrd  /boot/amd-ucode.img /boot/initramfs-6.2-x86_64.img
}
submenu 'Erweiterte Optionen für Manjaro Linux' $menuentry_id_option 'gnulinux-advanced-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
        menuentry 'Manjaro Linux (Kernel: 6.2.10-1-MANJARO x64)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.2.10-1-MANJARO x64-advanced-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod ext2
                search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
                linux   /boot/vmlinuz-6.2-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw  quiet resume=LABEL=swap apparmor=1 security=apparmor udev.log_priority=3
                initrd  /boot/amd-ucode.img /boot/initramfs-6.2-x86_64.img
        }
Found initrd fallback image: /boot/initramfs-6.2-x86_64-fallback.img
        menuentry 'Manjaro Linux (Kernel: 6.2.10-1-MANJARO x64 - fallback initramfs)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.2.10-1-MANJARO x64-fallback-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod ext2
                search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
                linux   /boot/vmlinuz-6.2-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw  quiet resume=LABEL=swap apparmor=1 security=apparmor udev.log_priority=3
                initrd  /boot/initramfs-6.2-x86_64-fallback.img
        }
        menuentry 'Manjaro Linux (Kernel: 6.2.10-1-MANJARO x64 - recovery mode)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.2.10-1-MANJARO x64-recovery-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod ext2
                search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
                linux   /boot/vmlinuz-6.2-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw single 
                initrd  /boot/initramfs-6.2-x86_64-fallback.img
        }
Linux-Abbild gefunden: /boot/vmlinuz-6.1-x86_64
initrd-Abbild gefunden: /boot/amd-ucode.img /boot/initramfs-6.1-x86_64.img
        menuentry 'Manjaro Linux (Kernel: 6.1.23-1-MANJARO x64)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.1.23-1-MANJARO x64-advanced-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod ext2
                search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
                linux   /boot/vmlinuz-6.1-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw  quiet resume=LABEL=swap apparmor=1 security=apparmor udev.log_priority=3
                initrd  /boot/amd-ucode.img /boot/initramfs-6.1-x86_64.img
        }
Found initrd fallback image: /boot/initramfs-6.1-x86_64-fallback.img
        menuentry 'Manjaro Linux (Kernel: 6.1.23-1-MANJARO x64 - fallback initramfs)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.1.23-1-MANJARO x64-fallback-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod ext2
                search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
                linux   /boot/vmlinuz-6.1-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw  quiet resume=LABEL=swap apparmor=1 security=apparmor udev.log_priority=3
                initrd  /boot/initramfs-6.1-x86_64-fallback.img
        }
        menuentry 'Manjaro Linux (Kernel: 6.1.23-1-MANJARO x64 - recovery mode)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.1.23-1-MANJARO x64-recovery-bd1d44ca-91e0-4a22-b906-6d798639c31c' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod ext2
                search --no-floppy --fs-uuid --set=root bd1d44ca-91e0-4a22-b906-6d798639c31c
                linux   /boot/vmlinuz-6.1-x86_64 root=UUID=bd1d44ca-91e0-4a22-b906-6d798639c31c rw single 
                initrd  /boot/initramfs-6.1-x86_64-fallback.img
        }
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/10_linux_proxy ###
/etc/grub.d/bin/grubcfg_proxy: /usr/lib/libcrypto.so.1.1: version `OPENSSL_1_1_0' not found (required by /etc/grub.d/bin/grubcfg_proxy)
/etc/grub.d/proxifiedScripts/linux: Zeile 208: version_find_latest: Kommando nicht gefunden.

❯ sudo update-grub
GRUB-Konfigurationsdatei wird erstellt …
Thema gefunden: /usr/share/grub/themes/manjaro/theme.txt
Linux-Abbild gefunden: /boot/vmlinuz-6.2-x86_64
initrd-Abbild gefunden: /boot/amd-ucode.img /boot/initramfs-6.2-x86_64.img
Found initrd fallback image: /boot/initramfs-6.2-x86_64-fallback.img
Linux-Abbild gefunden: /boot/vmlinuz-6.1-x86_64
initrd-Abbild gefunden: /boot/amd-ucode.img /boot/initramfs-6.1-x86_64.img
Found initrd fallback image: /boot/initramfs-6.1-x86_64-fallback.img
/etc/grub.d/bin/grubcfg_proxy: /usr/lib/libcrypto.so.1.1: version `OPENSSL_1_1_0' not found (required by /etc/grub.d/bin/grubcfg_proxy)
/etc/grub.d/proxifiedScripts/linux: Zeile 208: version_find_latest: Kommando nicht gefunden.

As written above I installed ‘grub-customizer’ a long time ago and then uninstalled it because it no longer works, I think!
at that time I had changed the default boot option and the timeout because of dual boot. nothing more.

here are the contents of /etc/grub.d/

/etc/grub.d🔒 
❯ ls
drwxr-xr-x    - root 16 Dez  2020  backup
drwxr-xr-x    - root 16 Dez  2020  bin
drwxr-xr-x    - root  1 Jan  2021  proxifiedScripts
.rwxr-xr-x 8,9k root  5 Apr 16:07  00_header
.rwxr-xr-x  270 root 16 Dez  2020  06_grub-customizer_menu_color_helper
.rwxr-xr-x  14k root  5 Apr 16:07  10_linux
.rwxr-xr-x 1,1k root  1 Jan  2021  10_linux_proxy
.rwxr-xr-x  14k root  5 Apr 16:07  20_linux_xen
.rwxr-xr-x  13k root  5 Apr 16:07  30_os-prober
.rwxr-xr-x 1,1k root  5 Apr 16:07  30_uefi-firmware
.rwxr-xr-x  722 root 31 Mär 13:15  35_fwupd
.rwxr-xr-x  214 root  5 Apr 16:07  40_custom
.rwxr-xr-x  215 root  5 Apr 16:07  41_custom
.rwxr-xr-x 1,2k root  9 Feb 22:50  60_memtest86+
.rw-r--r--  483 root  5 Apr 16:07  README

and here is the content of /etc/grub.d/10_linux_proxy

/etc/grub.d🔒 
❯ cat 10_linux_proxy 
#!/bin/sh
#THIS IS A GRUB PROXY SCRIPT
'/etc/grub.d/proxifiedScripts/linux' | /etc/grub.d/bin/grubcfg_proxy "+*
+#text
+'Manjaro Linux'~45e4e0c2642df9ef3359acf9967ec5c4~
+'SUBMENU' as 'Advanced options for Manjaro Linux'{+'Advanced options for Manjaro Linux'/*, +'Advanced options for Manjaro Linux'/'Manjaro Linux (Kernel: 5.9.11-3-MANJARO x64 - recovery mode)'~16b24cbd5c90da0c5512ac626748fd2b~, +'Advanced options for Manjaro Linux'/'Manjaro Linux (Kernel: 5.8.18-1-MANJARO x64 - recovery mode)'~5e6561432a1faaf58d573de367c9b5cb~, +'Advanced options for Manjaro Linux'/'Manjaro Linux (Kernel: 5.9.11-3-MANJARO x64)'~c6aa1bf901b9800096e0626423c516f0~, +'Advanced options for Manjaro Linux'/'Manjaro Linux (Kernel: 5.9.11-3-MANJARO x64 - fallback initramfs)'~aaacd5aefa257f93fe8f326964286927~, +'Advanced options for Manjaro Linux'/'Manjaro Linux (Kernel: 5.8.18-1-MANJARO x64)'~eee413f187f9a4d402691abaaa3935be~, +'Advanced options for Manjaro Linux'/'Manjaro Linux (Kernel: 5.8.18-1-MANJARO x64 - fallback initramfs)'~220f80c8f088889445559f2f690fc74f~}
"⏎    

Just gonna drop this here.

gcspt.sh
#!/usr/bin/env bash
gcspt=$(find /boot/ -type f -name grub.cfg);
initz=$(find /boot/ -type f -name 'initramfs*' | sort); 
imgz=$(find /boot/ -type f -name 'vmlinuz*' | sort); 
modz=$(find /lib/modules/ -maxdepth 1 -type d | sort);
mkinitz=$(find /etc/ -type f -name 'mkinitcpio*' 2>/dev/null | sort); 
mkinitzd=$(find /etc/mkinitcpio.d -type f | sort); 
printf '\n...Bite-Sized Boot-Info...\n'; 
printf "\nCurrently Running Kernel:\n$(hostnamectl | tail -n6 | head -n1 | awk '{ print $NF }')\n"; 
printf '\nGrub Configuration File:\n';
echo $gcspt | while read in; do ls -l --time-style=+'%F %R' "$in" | cut --complement -d ' ' -f1,2,3,4,5; done | column -t;
printf '\nInstalled Kernels:\n';
echo "$imgz" | while read in; do ls -l --time-style=+'%F %R' "$in" | cut --complement -d ' ' -f1,2,3,4,5; done | column -t; 
printf '\nInitramfs Images:\n'; 
echo "$initz" | while read in; do ls -l --time-style=+'%F %R' "$in" | cut --complement -d ' ' -f1,2,3,4,5; done | column -t;
printf '\nmkinitcpio:\n';
echo "$mkinitz" | while read in; do ls -l --time-style=+'%F %R' "$in" | cut --complement -d ' ' -f1,2,3,4,5; done | column -t;
echo "$mkinitzd" | while read in; do ls -l --time-style=+'%F %R' "$in" | cut --complement -d ' ' -f1,2,3,4,5; done | column -t;
printf '\nModule Directories:\n'; 
for i in $modz; do du --time --time-style=+'%F %R' -sh $i; done | awk '{print $2,$3,$4,$1}' | column -t; 
printf '\nHibernation:\n'; grep -o 'resume=' /etc/default/grub || printf 'No "resume=" option found in /etc/default/grub\n\n'

Remember to make sure to check if a package own a directory before manually removing it.

pacman -Qo /lib/modules/5.10.17-1-MANJARO 

PS.

Friendly reminder to anyone reading this. Please dont use this software.

unfortunately i can’t understand what your script does. nevertheless i solved the problem differently. but you are right, ‘grub-customizer’ is to blame!

This is no surprise.

Would you be so kind to let us know how exactly?