[mw_shl_code=applescript,false][root@www ~]# fdisk /dev/hdc
Command (m for help): n
First cylinder (2303-5005, default 2303): <==这里按[enter]
Using default value 2303
Last cylinder or +size or +sizeM or +sizeK (2303-5005, default 5005): +256M
Command (m for help): p
Device Boot Start End Blocks Id System
.....中间省略.....
/dev/hdc6 2053 2302 2008093+ 83 Linux
/dev/hdc7 2303 2334 257008+ 83 Linux <==新增的项目
Command (m for help): t <==修改系统 ID
Partition number (1-7): 7 <==从上结果看到的,七号partition
Hex code (type L to list codes): 82 <==改成 swap 的 ID
Changed system type of partition 7 to 82 (Linux swap / Solaris)
Command (m for help): p
Device Boot Start End Blocks Id System
.....中间省略.....
/dev/hdc6 2053 2302 2008093+ 83 Linux
/dev/hdc7 2303 2334 257008+ 82 Linux swap / Solaris
Command (m for help): w
# 此时就将 partition table 升级了!