Install FreeBSD, Linux, and Windows XP operating systems on the same computer

Source: Internet
Author: User
Tags naming convention linux

More and more hard drives make people have more choices, some people who are playing Linux are starting to try more operating systems, and people using Unix are starting to try Linux, while Windows XP is more convenient to do some work, this article is based on the idea that Make three systems exist in one hard drive and work well. The main content of this article is the hard disk partition and grub configuration installation of some of the essentials and basic knowledge of the explanation, not too in-depth details, I hope this article is helpful.

1. Before reading this article, we have several conventions:

The bootstrapper chooses grub--the new boot program is powerful and flexible I don't have to say, I know, do not know its proposal to find its information, and then the Lilo to change. :) Its function is the reason why I choose it.

We use a hard drive as an example, if you have more than one hard drive, you need to change some of the hard drive name parameters in the text.

The final agreement is important, that is, when you use this article as a guide, please back up your information, although I have been very careful and tested the full text of the various parts, but only on my computer successfully implemented, I do not guarantee on your computer successfully implemented.

2. Let's start by defining a few concepts:

A hard disk can be divided into four primary partitions, because only four partitions are logged in the MBR of the boot sector on the hard disk, and one of the comparisons that makes it easy to turn from Windows is that an extended partition is also one of the partitions that belong to an MBR master record. That is to say, if you divide a hard disk into four primary partitions, then you cannot split the extended partition; If you want to divide an extended partition, you can have a maximum of three primary partitions.

So, we can only divide four primary partitions, and only one partition is active, which is the default access partition that the system turns on after it is read into the MBR, reads the information from the boot sector of the partition to boot the partition's operating system, and directs the system, but like the Linux Lilo and grub in the MBR, One more way to boot the MBR is to directly specify a partition from which to load the boot sector of the specified partition and boot the partition's operating system.

By the way, extended partitions, as we all know, can be divided into multiple logical partitions within an extended partition. The information for the extended partition is recorded by the MBR, while the information for the logical partition is recorded by the boot sector of the extended partition.

This part is important, and the following will focus on using this knowledge:

In Linux, the partition of the hard disk is named this way.

If you have only one hard drive, and put it on the IDE1, then your hard drive name is called HDA in Linux, and the partitioning rule on the hard disk is: partition the primary partition from 1 (note that the primary partition here includes the extended partition, as is the case with the primary partition mentioned below), for example, You've divided three primary partitions on your hard drive, the first one is 1, the second is 2, the third is 3, and so on. What about the logical partition? Because a hard disk can only have four primary partitions, and the 1,2,3,4 is assigned to the primary partition in the naming convention, the logical partition can only be named from 5, which is why we see that logical partitions always start with 5. Okay, so we can just name our hard drive, for example, the first partition of your first hard disk is called HDA1, and the second partition of the first hard disk is called Hda2 ..., the first partition of the second hard disk is called the HDB1, and the second partition of the third hard disk is called HDC3, Analogy But if your first hard drive is divided into two areas, the second partition (HDA2) is an extended partition, and you have two logical partitions in the extended partition, then your naming will be this way:

The first partition is: HDA1

Second partition (that is, extended partition): Hda2

Second partition first logical partition: HDA5

Second partition second logical partition: Hda6

When you use Fdisk-l to view the partition information, there will be a similar display as follows:

Device Boot Start End Blocks Id System

/DEV/HDA1 * 1 638 5124703+ Linux

/DEV/HDA2 639 7476 39560062+ 5 Extended

/dev/hda5 7477 2615 514048+ Linux Swap

/dev/hda6 2616 3890 10241406 Linux

Grub's hard disk naming differs slightly from Linux:

For the IDE1 main disk, IDE1 from the disk, IDE2 the main disk, IDE2 from the disk named Hd0,hd1,hd2,hd3, that is, with 0-3 instead of a-d, the partition on each hard disk is also starting with the number of 0 to replace the original starting with the 1 Linux under the name, The logical partition of the extended partition is named after 4, so that the name under Linux is reduced by 1 in grub, and for example, the second partition of the third hard drive will be named hd2,1 the partition in the example above is as follows:

/DEV/HDA1-------(hd0,0)

/dev/hda2-------(hd0,1)

/dev/hda5-------(hd0,4)

/dev/hda6-------(hd0,5)

OK, all the preparation knowledge has been finished, if you have questions about the above content, suggest looking for other related content to see.

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.