silver.bullet at zoho.com
Mon Nov 30 07:19:29 UTC 2015
You didn't read
via the LiveCD terminal
This method uses the terminal from a LiveCD. The user must know the
device name/partition of the installed system (sda1, sdb5, etc), which
is then mounted from the LiveCD. GRUB 2 files are copied from the
LiveCD libraries to the proper locations and MBR.
This operation will write to the MBR and restore the modules and
core.img to /boot/grub. It will not replace or restore grub.cfg or fix
corrupted files. Boot the LiveCD, select "Try It", and open a terminal.
info.png When using a LiveCD, due to GRUB 2 changes between Ubuntu
releases, it is recommended that the user boots a LiveCD of the same
release (11.10, 12.04, etc) as the release to be repaired. If the user
has installed a different version of GRUB 2, use a LiveCD with the same
GRUB 2 version.
If necessary, use the fdisk command to help determine the partition on
which Ubuntu is installed. The fdisk option "-l" is a lowercase "L".
Look for one of the appropriate size or formatting. Running sudo blkid
may provide more information to help locate the proper partition,
especially if the partitions are labeled. The '
sudo fdisk -l
In the following commands:
Use the partition number of the Ubuntu installation with mount
Do not use the partition number with the grub-install command.
X is the drive letter (a, b, c, etc.); Y is the partition number
(1, 5, etc).
--boot-directory is the folder in which the GRUB folder is located.
This is normally /boot but should be changed if the grub folder is
On systems with a separate /boot partition, that partition should
be mounted to /mnt/boot. For instance:
sudo mount /dev/sda6 /mnt/boot
grub-install will restore missing files in the grub folder but will
not restore intentionally deleted or corrupted files. To accomplish
these tasks GRUB 2 must be completely removed and reinstalled.
sudo mount /dev/sdXY /mnt # Example: sudo mount /dev/sda5 /mnt
sudo grub-install --boot-directory=/mnt/boot /dev/sdX # Example:
sudo grub-install --boot-directory=/mnt/boot /dev/sda
More information about the ubuntu-users