Practical solutions for retrieving lost Linux boot items after Windows 7 is re-installed

Source: Internet
Author: User

After win7 is permanent, there will always be various problems, or you may feel new about changing to a pure system or something. If you are a dual system, the poor Linux Startup item will be killed by the domineering Windows Startup item, what should we do? How can we find the lost Linux Startup items? Next, we will explain it in combination with our own practices. There are also many issues related to the Internet.ArticleMost of them are reprinted. I do not know how many articles I have actually practiced. Today I just practiced it myself. I will summarize most articles on the Internet.

Method 1: Use the Linux installation disk to enter the trial mode.

This method is feasible, and there are n similar articles on the internet, Google. I don't like this method, but I don't like it here. I don't have to install a disk or start a USB flash drive (I'm too lazy to do it)

Method 2: UseGrldr operations

This method has also been reposted many times. Google is the specific method. I failed to try it. I feel that this method is suitable for the XP system and I am not very familiar with Windows 7.

Method 3: Use easybcd for restoration

This method is suitable for those who do not have livecd. It can be said that this method is basically the same as the steps for installing the system.The vmlinuz and initrd. LZ files under the/Casper/folder are stored in the root directory of drive C. Of course, the Linux image files also need to be copied to the root directory of drive C. Open easybcd and perform operations


After you click config, a text file will pop up and fill in the relevant items of the startup Item. Here I will provide a template and modify the Linux image name myself.

Title install linuxmint
Root (hd0, 0)
Kernel (hd0, 0)/vmlinuz boot = Casper iso-Scan/filename =/linuxmint-14-kde-dvd-64bit.iso Ro quiet splash locale = zh_CN.UTF-8
Initrd (hd0, 0)/initrd. LZ

My configurations


The first line indicates the name to be displayed, can be casually written, generally windows are installed on the C disk, 7th line to write, 8th line of "linuxmint-14-kde-dvd-64bit.iso" indicates the name of the image file, this must be the same as your own image (the ISO image copied to the C-drive root directory.

Now we can launch easybcd to restart and perform the restoration operation!

After the restart, select the new project. Enter the Linux trial and open the terminal and enter sudo umount-L/isodevice.

The following is the actual command operation. I hope you can read it carefully.

Terminal InputSudo fdisk-L: Check the partition mounting status (Do you still remember your partition on Linux ?)

For example, my partitions are as follows:


As you can see, I have separately partitioned the/root partition and/home partition. Next I will mount these partitions to retrieve the original grub for installation.

Mkdir/Media/tmp

Mount
/Dev/sda8/Media/tmp mount the root partition/

Mount
/Dev/sda10/Media/tmp/home Mount/home partition (PS: If you have a separate partition for the/home partition, you must attach it if you have other separate partitions)

Grub-install
-Root-directory =/Media/tmp/dev/SDA install grub

After the last command is executed, some error messages may appear, but ifThe statement installation finished. No error reported. "indicates that the statement is correctly executed. Basically, it is almost finished. Restart the program to Linux (do not enter windows for the time being, but the boot item is not fully prepared yet)

Open the terminal again and enter

Sudo
Update-grub2 for grub updates, it will automatically search for the boot items included in the system, okay, now it's done


Related Article

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.