Install Linux on hard disk and start Linux from Grub command line (1)

Source: Internet
Author: User

This article describes how to install Linux on the hard disk and start Linux from the Grub command line. It is helpful for readers who want to install Linux on the hard disk and start Linux from the Grub command line.

1. install Linux from hard disk

I would like to talk about the principle of disk partitioning, but it may seem lengthy and time-consuming, so I will directly provide the hard disk installation guide). If you want to be clear, please refer to several articles on hard disk partitioning. In addition, my C drive is in FAT32 format. If your windows system partition is not in this format, for example, NTFS format, I do not know if it is feasible or not, it is said that the current kernel is supported.

The descriptions below are as specific as possible, but you can do anything else to make smart changes.

1. Back up your important data to avoid any problems. Generally, you will distribute a disk in the Windows system to Linux. My solution is to back up data to another disk, for example, four disks, C, D, E, and F, if I want to install Linux on disk F, I will back up the data on disk F to disk D or disk E. Of course, I will still put the most important files such as love letters) copy to the mobile storage media.

Note: to change the Partition size, for example, to increase disk F, use the corresponding software, for example, Partition Manager. Read the help files of the software during use.

2 download GRUB for DOS, web site for http://newdos.yginfo.net/grubdos.htm, can download the latest version, download copy to C disk, decompress to the subdirectory with Winrar, rename this directory to grub to correspond to the following directory ). Note: My C drive is FAT32, and the following process only applies to this format. As for the results of the NTFS format, I cannot test it. You can try it on your own.

3. In Windows XP, open "my computer", go to drive C, and click "Tools> Folder Options> View ", deselect the "Hide protected operating system files" option in advanced settings and select "show all files and directories. In this way, you can see some operating system files. Enable boot. ini file, add the C: \ GRLDR = "Run GRUB" storage at the end, copy the grldr file under the grub directory to the C root directory, and finally copy it to C: \ grub \ boot creates an entire grub directory under C: \ boot ).

4 download the released version of the CD image file, if you want to install Hiweed-debian, please go to the ftp://debian.ustc.edu.cn/debian-cd/hiweed-debian/ directory to download a CD image the latest version is "National Day cracked version", that is, * 0.55 _ i386.iso ), put the downloaded file in the root directory of the C drive, and then download the file in the hiweed-hard-disk-install subdirectory, and put it in the root directory of the C drive. If you want to install Red Hat 9.0, you can go to ftp: // 202.38.64.123/to download the CD image. There are three image files in total, and the CD image is also placed in the C root directory, then, use Winrar/WinImage to open the first image file and extract the initrd. img and vmlinuz files are stored in the C root directory. If you want to install a later version of Fedora Core 2Red Hat), you can go to ftp: // 202.38.75.11/to download the CD image. There are four image files in total, and the CD image is still in the C root directory, then, use Winrar/WinImage to open the first image file and extract the initrd. img and vmlinuz files are stored in the C root directory.

NOTE: If Hiweed-debian is installed, make sure the following files exist in the root directory of the C drive.

Vmlinuz is downloaded from the ftp server, as described above)

Initrd.gz is downloaded from the ftp server, as described above)

Hiweed-debian-desktop_0.55_i386.iso

If Red Hat 9.0 is installed, make sure the following files exist in the root directory of the C drive.

Shrike-i386-disc1.iso

Shrike-i386-disc2.iso

Shrike-i386-disc3.iso

Vmlinuz extracted from shrike-i386-disc1.iso)

Initrd. img extracted from shrike-i386-disc1.iso)

If Fedora Core 2 is installed, make sure the following files exist in the root directory of the C drive.

FC2-i386-disc1.iso

FC2-i386-disc2.iso

FC2-i386-disc3.iso

FC2-i386-disc4.iso

Vmlinuz extracted from FC2-i386-disk1.iso)

Initrd. img extracted from FC2-i386-disk1.iso)

5. restart the computer. There are two menu items for you to choose from. One of them is the "run GRUB" added above. Select and press enter to start running the GRUB program. No matter what you see, press the keys 'C '.

6. Follow these steps to guide Hiweed-debian: grub> kernel (hd0, 0)/vmlinuz root =/dev/ram ramdisk_size = 10000
Devfs = mount, dall

Grub> initrd (hd0, 0)/initrd.gz

Grub> boot

Follow these steps to guide Red Hat 9.0:

Grub> kernel (hd0, 0)/vmlinuz root =/dev/ram ramdisk_size = 10000

Devfs = mount, dall

Grub> initrd (hd0, 0)/initrd. img

Grub> boot

Follow these steps to guide Fedora Core 2:

Grub> kernel (hd0, 0)/vmlinuz root =/dev/ram ramdisk_size = 10000

Devfs = mount, dall

Grub> initrd (hd0, 0)/initrd. img

Grub> boot

Tip: You can use the TAB key to complete commands or parameters in grub. For example, Type

Grub> initrd (hd0, 0)/init

Then press the TAB key, and grub will automatically add the specified initrd “initrd.gz "or" initrd. img ".

7. After the boot is successful, you can install the system. For details about the installation, refer to other articles. If Red Hat 9.0 or Fedora Core 2 is installed, the installer will ask you where to install it. Select "Hard disk" and select/dev/hda1 as the location of the image file. In fact, the installation process is relatively simple. For Fedora Core 2, if your machine is in mainstream settings, you will find that it is an image interface during installation, as long as you have installed a Windows system, you will find the process so familiar!


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.