Explanation on why Linux can only be divided into four sectors

Source: Internet
Author: User
The following is an explanation of why Linux can only be divided into four sectors-Linux general technology-Linux technology and application information. Some people have asked why there are only four primary partitions and four extended partitions when installing Linux. At that time, due to insufficient basic knowledge, the problem cannot be solved in a timely manner. I am a little embarrassed.

MBR (Master Boot Recorder) Stores hard disk information in the Main Boot Sector. MBR can be said to be the most important part of the entire hard disk, because two important items are recorded in MBR: The Boot Management Program and the partition table ). Therefore, we are modifying the partition table.

Due to the limited capacity of this MBR block, only four split records are designed at the time of design. These split records are called Primary) and Extended (Extended division), that is, a hard disk can have up to four Primary + Extended sectors, of which, Extended can have only one. Therefore, if you want to split it into four disks, you can:

P + P
P + E

. Note that, in the above case, 3 P + E only has three "available" disks. If four disks are "available", the score is cut to 4 P! (Because Extended cannot be used directly, it must be split into Logical)
Think 1: If I want to divide my big hard drive into four partitions for the moment, and there is other space for me to plan in the future, how should I split it?

From the preceding description, we can know that Primary + Extended can have up to four partitions. If you want to have more than five partitions, you need Extended help. Therefore, in this example, we cannot divide it into four Primary. Why? If you are a 20 GB hard disk and 4 primary share 15 GB, do you think there are 5 GB available? Error! The remaining 5 GB cannot be used at all. This is because there is no additional partition table Record area to record, so no additional division can be performed, of course ??? Master the notebook, master the Huanhuan Shuo training, and play tricks? Why? Too many tasks? Why ??? Refers to memory? When there are more than 4 slots, remember to have an Extended partition, and you must allocate all the remaining space to Extended, and then plan the Extended space using the logical partition.

Thinking 2: Can I separate only one Primary and one Extended?

Of course! Basically, there can be 64 Logical shards. Therefore, you can divide only one primary shard and all other shards are Extended. You can use Logical shards to plan other shards!
Think 3 if I want to split my hard disk into six usable hard disk sectors installed on the Master of IDE 1, what is the code of each disk under Linux?
Note:

Since the hard disk can have up to four partitions in Primary + Extended mode, in Linux, the partition table 1 ~ 4. Leave it first. If only two P + E are used, two partition numbers will be blank! For more details, let's assume that I have used up all four P + E. Extended/dev/hda4 contains three logical partitions.

Actually, you can use the/dev/hda1,/dev/hda2,/dev/hda3,/dev/hda5,/dev/hda6,/dev/hda7 partition! The Extended sector/dev/hda4 is only used to plan the disk space that can be used by Logical!

So what if I only want to split one Primary and one Extended?

Because 1 ~ The number 4 has been reserved, so the code of the first Logical is calculated from the number 5, and the disk code is added in the accumulative way when it is planned later ?? 《? Logs/dev/hda3 and/dev/hda4 are empty and Reserved codes.

NOTE: For the above content, refer to "laruence's Linux private house dish.
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.