[root@centos6 ~]# fdisk /dev/sdc
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
switch off the mode (command 'c') and change display units to
sectors (command 'u').
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-2088, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-2088, default 2088):
Using default value 2088
Command (m for help): p
Disk /dev/sdc: 17.2 GB, 17179869184 bytes
255 heads, 63 sectors/track, 2088 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xa1c3a1c3
Device Boot Start End Blocks Id System
/dev/sdc1 1 2088 16771828+ 83 Linux
在完成之前,我们必须设置启动标志和分区系统ID,分区系统ID必须是WINDOWS的,ID值为 7.
代码如下:
Command (m for help): A
Partition number (1-4): 1
Command (m for help): t
Selected partition 1
Hex code (type L to list codes): 7
Changed system type of partition 1 to 7 (HPFS/NTFS)
Command (m for help): p
Disk /dev/sdc: 17.2 GB, 17179869184 bytes
255 heads, 63 sectors/track, 2088 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xa1c3a1c3
Device Boot Start End Blocks Id System
/dev/sdc1 * 1 2088 16771828+ 7 HPFS/NTFS
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@centos6 ~]# ntfsresize /dev/sdc1</p> <p> ntfsresize v2013.1.13 (libntfs-3g)
Device name : /dev/sdc1
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 10725732864 bytes (10726 MB)
Current device size: 17174352384 bytes (17175 MB)
New volume size : 17174348288 bytes (17175 MB)
Checking filesystem consistency ...
100.00 percent completed
Accounting clusters ...
Space in use : 7565 MB (70.5%)
Collecting resizing constraints ...
WARNING: Every sanity check passed and only the dangerous operations left.
Make sure that important data has been backed up! Power outage or computer
crash may result major data loss!
Are you sure you want to proceed (y/[n])? y
Schedule chkdsk for NTFS consistency check at Windows boot time ...
Resetting $LogFile ... (this might take a while)
Updating $BadClust file ...
Updating $Bitmap file ...
Updating Boot record ...
Syncing device ...
Successfully resized NTFS on device '/dev/sdc1'.