Dual-drive dual-Win8 and Ubuntu repair Grub

Source: Internet
Author: User

Dual-hard drive dual-win8 and Ubuntu are the conditions. grub cannot be started anymore. You need to fix it so that it can start the three systems. The specific distribution is: Hard Disk A + Win8A hard disk B + Win8B + ubuntu. Win8 is started by default.

Use LinuxLive USB Creator to create usb live and then start the USB flash drive.

Linux installation assistant LiLi USB Creator 2.8.25 released

Follow these steps:

--------------------------------------------------------------------------

How to Repair, Restore, or Reinstall Grub 2 with a Ubuntu Live CD or USB

Grub 2 typically gets overridden when you install Windows or another Operating System. To make Ubuntu control the boot process, you need Reinstall (Repair/Restore) Grub using a Ubuntu Live CD.

Warning:

Using the sudo command, especially from a Live CD can do serious damage to your system. read all instructions and confirm you understand before executing any commands. when pasting into the Terminal, use Ctrl + Shift + V, NOT Ctrl + V.

Terminal Commands:

Mount the partition your Ubuntu Installation is on. if you are not sure which it is, launch GParted (sorted in the Live CD) and find out. it is usually a EXT4 Partition. replace the XY with the drive letter, and partition number, for example: sudo mount/dev/sda5/mnt.

Sudo mount/dev/sdXY/mnt

Now bind the directories that grub needs access to detect other operating systems, like so:

Sudo mount -- bind/dev/mnt/dev & sudo mount -- bind/dev/pts/mnt/dev/pts & sudo mount -- bind/proc/mnt/proc && sudo mount -- bind/sys/mnt/sys

Now we jump into that using chroot.

Now install, check, and update grub.

This time you only need to add the drive letter (usually a) to replace X, for example: grub-install/dev/sda, grub-install-recheck/dev/sda.

Grub-install/dev/sdXgrub-install -- recheck/dev/sdX

Now grub is back, all that is left is to exit the chrooted system and unmount everything.

Exit & sudo umount/mnt/dev/pts & sudo umount/mnt/proc & sudo umount/mnt/sys & sudo umount/ mnt

Shut down and turn your computer back on, and you will be met with the default Grub2 screen.

You may want to update grub or re-install burg however you like it.

Congratulations, you have just recyclred/Restored/Reinstalled Grub 2 with a Ubuntu Live CD!

--------------------------------------------------------------------------

Note:

1. the ubuntu version used for usb live must be the same as the number of BITs installed on the hard disk (32 or 64 at the same time) and preferably the same version. Otherwise, some commands cannot be used.

2. for grub-install/dev/sdX in step 1, if the "X" Behind it is the hard disk currently started by default, as in this case, it should correspond to hard disk.

3. To view the ubuntu VERSION that cannot be started on the hard disk, you can view it in/etc/OS-release or grep "VERSION"/etc-rn.

4. If "chroot: failed to run command '/bin/bash': Exec Format error" is encountered, 1 error is returned.

5. Modify/etc/grub. d/30_os-prober to enable Win8 by default, because it will prober two win8 and does not know which one to start. Modify/boot/grub. cfg if you want to modify it.

Ubuntu 13.10 download, installation, and configuration summary page

For more information about how to install Ubuntu 13.10 on a hard drive in Windows 7, see

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.