The first step is to add a new hard disk on the virtual machine;
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_14142396557KmU.png "" 1131 "height=" 522 "/>
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239656eyAq.png "594" height= "446"/> 650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239657cECv.png "" 570 "height=" 455 "/>
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_14142396570LV6.png "" 548 "height=" 421 "/>
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239658sRSG.png "" 403 "height=" 284 "/>
When you have finished adding your hard disk, you will receive:
Rebooting the system
Second step partition;
1) View disk information;
Command: FDISK–L View all disk information
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239658wKBU.png "" 555 "height=" 311 "/>
2) interactive commands;
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239660nPvj.png "" 727 "height=" 473 "/>
3) Create partitions;
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239661MTih.png "" 518 "height=" 542 "/>
The primary partition can have up to four, and the extended partition may be multiple. The specific reasons are as follows:
The
is determined by the initial design architecture of the personal computer. At first, the PC was designed to start the process, the motherboard BIOS self-test when the boot, when everything OK, began to read the first sector of the hard disk, a sector size is 512 bytes, this is the computer industry standard, no matter what hard disk, The size of a sector is 512 bytes. The BIOS reads and executes the 512-byte content. These 512 bytes are called the MBR (Master boot record) master boot record. This 512 contains the most important information about the hard disk: the partition table. Because space is only a mere 512 bytes, the size of the partitioned table is very limited, He was designed to be very small but enough to describe the partition of the hard drive. Includes the start sector of the partition, the end sector, the boot flag, the partition type, and so on. Each partition information is represented by 16 bytes, and four partitions are used to 16x4=64 bytes, and the 64 bytes are distributed in the 第467-510 bytes of the MBR. Immediately after the two bytes AA and 55 are called Magic Numbers (magic number), Bois reads the MBR when always checking whether there are two magic numbers at the end, and if not, it is considered to be a hard disk that is not partitioned. Even if there is data in the partition table, there will be an error, telling you that the system does not exist. The simple way to encrypt a hard disk is to take these two bytes out of the MBR. The hard drive that hangs on any computer will appear as a blank hard disk with no partitions. But as long as the two bytes are re-written, the data can be read again. Of course, you need to know how to re-write. The
Primary partition, also known as primary disk partition, is a type of partition, just like an extended partition or logical partition. Other types of partitions can no longer be partitioned in the primary partition, so each primary partition is equivalent to a logical disk (the primary partition is similar to the logical partition at this point, but the primary partition is partitioned directly on the hard disk, and the logical partition must be built into the extended partition). The
actually has no concept of primary partitions, extended partitions, and logical partitions in the earlier hard disk partitions, each of which is now called the primary partition. Since the hard disk retains only 64 bytes of storage for the partitioned table, and the parameters for each partition occupy 16 bytes, the total in the main boot sector can only store data for 4 partitions. In other words, a physical hard disk can only be divided into 4 logical disks. In a specific application, 4 logical disks often fail to meet the actual requirements. To create more logical disks for use by the operating system, extended partitions and logical partitions are introduced, and the original partition type is referred to as the primary partition.
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239661Yzue.png "" 594 "height=" 328 "/>
To continue creating the partition:
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_14142396628YK2.png "" 766 "height=" 717 "/>
To delete a partition, create an extended partition:
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_1414239663H4OJ.png "" 677 "height=" 646 "/>
650) this.width=650; "title=" image "style=" border-top:0px; border-right:0px; border-bottom:0px; border-left:0px; Display:inline "border=" 0 "alt=" image "src=" http://img1.51cto.com/attachment/201410/25/2664956_14142396645Swj.png "" 496 "height=" 338 "/>
To this, the disk partition ends.
--------------------------------------------------------------------------------------------------------------- ------------------------------------------------
Think of one: if I want to partition my large hard drive into four partition, and there are other spaces that allow me to plan in the future, how do I partition it?
By just stating, we can know that Primary + Extended can only have up to four partition, and if more than 5 partition, then need Extended help. Therefore, in this case, we must not partition into four Primary why? If you're a 4 GB hard drive, and you have a total of 5 gigabytes of primary, you think you're going to be able to use it, right? Wrong! The remaining 5 GB is completely unusable because there is no extra partition table record area to record, so no additional partitions can be made, and of course, space is wasted! Therefore, please be aware that if you want to partition more than 4 slots, please remember to have Extended partition, and all the rest of the space must be allocated to Extended, and then the logical partition area to plan Extended space.
Think two: Can I partition only 1 Primary and 1 Extended?
Of course! Basically, Logical can have 64, so you can partition only one primary partition and give all other partitions to Extended, and use Logical partition for other partition planning!
Think three: If my hard disk is installed in the IDE 1 Master, and I want to partition into 6 can use the hard disk sector, then each disk under Linux code name?
Description
Since the hard disk can have up to four Primary + Extended, under Linux, the partition Table 1 ~ 4 has been left, and if only 2 P + E is used, then two partition Numbe will be vacated R Yo! In more detail, let's say I ran out of four P + E. Where EXTENDED/DEV/HDA4 consists of three logical partitions.
The actual can use is/dev/hda1,/dev/hda2,/dev/hda3,/dev/hda5,/dev/hda6,/dev/hda7 these six partition! As for/DEV/HDA4, the Extended sector itself is only used to plan the amount of disk space Logical can use!
So what if I just want to partition 1 Primary and 1 Extended?
Because the 1~4 number has been reserved, so the first Logical code is calculated from number 5th, and later in the plan, add the disk code in a cumulative way! And/dev/hda3,/dev/hda4 is empty, is retained the code name.
This problem, combined with history, will be more accurate. Why is it possible to divide up to four primary partitions, not solely by the operating system.
First, why is a sector only 512 bytes, why not 1024 bytes?
First, I want to say how many bytes a sector can be defined by itself (hard drive manufacturer), which can be 1024 bytes. So, a sector that is 512 bytes is not a theoretical value, but a customary value. That is, the size of a sector of 512 bytes for the hard disk manufacturers are accustomed to this definition, who do not want to change this habit.
Second, the first sector of the hard disk can be divided into three parts: the first part of the MBR, need to occupy 446 bytes, the second part of the DPT, the need to occupy 64 bytes, this is because a partitioned table needs to occupy 16 bytes, 64/16=4, so just can store four partitions of the table, which is why only divided into four partitions. There are two bytes to store the end flag. Such
446+64+2=512 bytes.
Encrypting a hard disk is actually rewriting the last two-byte end flag.
Imagine if the hard drive manufacturers to set a sector to 1024 bytes, or can only be divided into four partitions? A logical drive also needs a partitioned table, which is stored in the first sector of the extended partition, so the logical drive is not just a random number of points.
VMware disk mount partition (i)