Depending on the cause of your problem, updating or reinstalling the GRUB bootloader may be sufficient to fix it. One way to attempt that is to follow these the steps below.
Determine your normal system partition:
sudo fdisk -l
Look for the /
partition.
If the partition is /dev/sda2, mount the partition:
sudo mount /dev/sda2 /mnt
You may need to change /dev/sda2
to a different partition, depending on what you discovered in the first step.
Bind-mount some other necessary stuff:
for i in /sys /proc /run /dev; do sudo mount --bind "$i" "/mnt$i"; done
chroot
into your Ubuntu install:
sudo chroot /mnt
Now you're running your install in root and not the live CD so you can run:
update-grub
If you face errors, you might have to re-install GRUB
grub-install /dev/sda
update-grub
Usually this is /dev/sda
, but if your system is installed on a different physical disk (as revealed in the first step), you may need to change this accordingly to say /dev/sdb
, /dev/sdc
, etc.
Hopefully everything works. Run these commands to exit the chroot
and reboot the system:
exit
sudo reboot
For other ways to repair GRUB and further explanation, see RecoveringUbuntuAfterInstallingWindows and Grub2/Installing → Fixing a Broken System.