1. after adding a new hard disk, you can use fdisk-l to view and confirm the new hard disk. In linux, device files are stored in/dev: 1) IDE hard disk is represented as hd, SCSI is represented as sd, 2) The first block is represented as. The second part is B, and so on. For example, the hard disk of the first IDE is hda3. the partition is represented by numbers. The primary partition is 1--4, and the logical partition is 5.
1. after adding a new hard disk, you can use fdisk-l to view and confirm the new hard disk.
In linux, the device files are stored in/dev:
1) IDE hard disk is represented as hd, SCSI is represented as sd,
2) The first part is represented by. The second part is B, and so on. For example, the hard disk of the first IDE is hda.
3) partitions are represented by numbers. The primary partition is 1--4 and the logical partition is 5--X. For example
Primary partitionsIt is hda1, the first logical partition is hda5, and the second logical partition is hda6. This
And so on.
4) device: device name of the partition
Boot: Whether to start the boot partition
Start: number of start columns in a partition
End : Number of ending cylinders in a partition
Blocks: partition size
Id : ID of the partition
System: partition type
Partition graphic explanation "title =" linux"Id =" image_operate_81941359125680406 "/>
2. this is a partition ID and the corresponding file system type. in linux, there are only four commonly used types. what I check is.
82 linux swap (Swap partition system) this partition type is used to solve the physical memory shortage, similar to the virtual memory in windows.
83 linuxEXT3 Default partition system type in linux
8e linuxLVM LVM Logical Volume in linux
5Linux extended partitions
Partition graphic explanation "title =" linux"Id =" image_operate_10891359125765171 "/>
3. use fdisk to enter the interactive partition management interface, as shown in. Press m to enter the help page.
Partition graphic explanation "title =" linux"Id =" image_operate_23911359125751265 "/>
4. I will organize the information on this interface below. you can learn it by comparison. Common options are highlighted in blue.
Partition graphic explanation "title =" linux"Id =" image_operate_90441359123764671 "/>
5. look at the table above and start partitioning ...... P. check the current partition ......
Partition graphic explanation "title =" linux"Id =" image_operate_86861359128574296 "/>
6. create a 20g primary partition. ECreate an extended partition
PCreate a primary partition
Parfitionnumber primary partition number
Number of cylinder at the beginning of Firstcylinder. the default value is 1. press Enter.
LastcylinderPartition size
Partition graphic explanation "title =" linux"Id =" image_operate_27391359128549828 "/>
7. view the existing primary partition ......
Partition graphic explanation "title =" linux"Id =" image_operate_69425359128460890 "/>
8. create a 40 GB extended partition.
Partition graphic explanation "title =" linux"Id =" image_operate_52510959128435468 "/>
9. now we can see that we have created an extended partition/dev/sdb2.
Partition graphic explanation "title =" linux"Id =" image_operate_32541359128235921 "/>
10. create a logical partition on the extended partition we have created. Logical
Partition graphic explanation "title =" linux"Id =" image_operate_82511359130064765 "/>
11. now we can see the created logical partition.
Partition graphic explanation "title =" linux"Id =" image_operate_57561359129519531 "/>
12. delete a partition. Use d
Partition graphic explanation "title =" linux"Id =" image_operate_48921359129592609 "/>
13. use w to save the created partition and exit ......
Partition graphic explanation "title =" linux"Id =" image_operate_59801359129786156 "/>
14. use fdisk-l again to see the created partition.
Partition graphic explanation "title =" linuxPartition text description "id =" image_operate_71731359129789890 "/> partition text description" title = "linux"Id =" image_operate_846613591298000078 "/>
15. format the partition with mkfs ...... You can first check the mkfs related files ......
Partition graphic explanation "title =" linux "Id =" image_operate_14491359129892812 "/>
16. when mkfs does not match any options, you can format the specified partition according to the allocated system type.
-T can be used to specify the type.
Partition graphic explanation "title =" linux"Id =" image_operate_5901359129938406 "/>
Partition graphic explanation "title =" linux"Id =" image_operate_90341359130000359 "/>
17. df is used to view mounted devices and no/sdb is found. Therefore, we need to mount them before using them ......
Partition graphic explanation "title =" linux"Id =" image_operate_96841359130033843 "/>
18. Mount/dev/sdb5.. use df to check whether the disk has been mounted.
Partition graphic explanation "title =" linux"Id =" image_operate_49491359130034078 "/>