Command (m for help): m #列出所有內(nèi)部命令及功能說明 Command action a toggle a bootable flag b edit bsd disklabel ......省略部分輸出內(nèi)容...... w write table to disk and exit x extra functionality (experts only)
(3)使用"n"命令創(chuàng)建新的硬盤分區(qū)。在命令行中輸入下面的命令:
Command (m for help): n #創(chuàng)建新的分區(qū) Command action e extended p primary partition (1-4) p#創(chuàng)建主分區(qū) Partition number (1-4): 1#指定主分區(qū)編號(hào) First cylinder (1-1044, default 1): 1#指定起始柱面 Last cylinder or +size or +sizeM or +sizeK (1-1044, default 1044): +300M #指定分區(qū)大小
(4)使用"p"命令顯示分區(qū)列表。在命令行中輸入下面的命令:
Command (m for help): p #顯示分區(qū)列表 Disk /dev/sdb: 8589 MB, 8589934592 bytes 255 heads, 63 sectors/track, 1044 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sdb1 1 37 297171 83 Linux
(5)使用"w"命令保存并退出fdisk指令。在命令行中輸入下面的命令:
Command (m for help): w #保存分區(qū)表并退出 The partition table has been altered! Calling ioctl() to re-read partition table. Syncing disks.