GRUB recovery is needed when a system no longer reaches the boot menu or when another operating system has overwritten the bootloader. The safest approach is to boot from live media, identify the installed Linux system, then reinstall GRUB carefully.
Identify disks and partitions
lsblk
sudo fdisk -l
Confirm the root partition and the boot mode, especially on UEFI systems where an EFI System Partition is involved.
Mount and chroot
sudo mount /dev/sdXN /mnt
sudo mount --bind /dev /mnt/dev
sudo mount --bind /proc /mnt/proc
sudo mount --bind /sys /mnt/sys
sudo chroot /mnt
Reinstall and rebuild the menu
grub-install /dev/sdX
update-grub
Use the disk name for grub-install, not a numbered partition, unless your distribution has different instructions. Reboot only after checking for errors.