Topic: (SOLVED)Problem Resizing NTFS with new live 5.03 disk
I attempted to resize a NTFS partition and it failed with the now well know bug. I though the new live cd was patched but apparently it is not. Below is the log, I have reposted it as a new topic as requested.
GParted 0.5.0
Libparted 1.9.0
Move /dev/hda3 to the right and shrink it from 36.31 GiB to 25.13 GiB 01:08:41 ( ERROR )
calibrate /dev/hda3 00:00:03 ( SUCCESS )
path: /dev/hda3
start: 80148285
end: 156296384
size: 76148100 (36.31 GiB)
calculate new size and position of /dev/hda3 00:00:01 ( SUCCESS )
requested start: 103603185
requested end: 156296384
requested size: 52693200 (25.13 GiB)
new start: 103603185
new end: 156296384
new size: 52693200 (25.13 GiB)
check file system on /dev/hda3 for errors and (if possible) fix them 00:00:01 ( SUCCESS )
ntfsresize -P -i -f -v /dev/hda3
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 38987825664 bytes (38988 MB)
Current device size: 38987827200 bytes (38988 MB)
Checking for bad sectors ...
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15330 MB (39.3%)
Collecting resizing constraints ...
Estimating smallest shrunken size supported ...
File feature Last used at By inode
$MFT : 21893 MB 0
Multi-Record : 19477 MB 416
$MFTMirr : 19494 MB 1
Ordinary : 35248 MB 1745
You might resize at 15329005568 bytes or 15330 MB (freeing 23658 MB).
Please make a test run using both the -n and -s options before real resizing!
shrink file system 00:01:38 ( SUCCESS )
run simulation 00:00:04 ( SUCCESS )
ntfsresize -P --force /dev/hda3 -s 26978918399 --no-action
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 38987825664 bytes (38988 MB)
Current device size: 38987827200 bytes (38988 MB)
New volume size : 26978910720 bytes (26979 MB)
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15330 MB (39.3%)
Collecting resizing constraints ...
Needed relocations : 178662 (732 MB)
Schedule chkdsk for NTFS consistency check at Windows boot time ...
Resetting $LogFile ... (this might take a while)
Relocating needed data ...
Updating $BadClust file ...
Updating $Bitmap file ...
Updating Boot record ...
The read-only test run ended successfully.
real resize 00:01:34 ( SUCCESS )
ntfsresize -P --force /dev/hda3 -s 26978918399
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 38987825664 bytes (38988 MB)
Current device size: 38987827200 bytes (38988 MB)
New volume size : 26978910720 bytes (26979 MB)
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15330 MB (39.3%)
Collecting resizing constraints ...
Needed relocations : 178662 (732 MB)
Schedule chkdsk for NTFS consistency check at Windows boot time ...
Resetting $LogFile ... (this might take a while)
Relocating needed data ...
Updating $BadClust file ...
Updating $Bitmap file ...
Updating Boot record ...
Syncing device ...
Successfully resized NTFS on device '/dev/hda3'.
You can go on to shrink the device for example with Linux fdisk.
IMPORTANT: When recreating the partition, make sure that you
1) create it at the same disk sector (use sector as the unit!)
2) create it with the same partition type (usually 7, HPFS/NTFS)
3) do not make it smaller than the new NTFS filesystem size
4) set the bootable flag for the partition if it existed before
Otherwise you won't be able to access NTFS or can't boot from the disk!
If you make a mistake and don't have a partition table backup then you
can recover the partition table by TestDisk or Parted's rescue mode.
shrink partition from 36.31 GiB to 25.13 GiB 00:00:01 ( SUCCESS )
old start: 80148285
old end: 156296384
old size: 76148100 (36.31 GiB)
new start: 80148285
new end: 132841484
new size: 52693200 (25.13 GiB)
check file system on /dev/hda3 for errors and (if possible) fix them 00:00:01 ( SUCCESS )
ntfsresize -P -i -f -v /dev/hda3
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 26978910720 bytes (26979 MB)
Current device size: 38987827200 bytes (38988 MB)
Checking for bad sectors ...
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15329 MB (56.8%)
Collecting resizing constraints ...
Estimating smallest shrunken size supported ...
File feature Last used at By inode
$MFT : 21893 MB 0
Multi-Record : 19477 MB 416
$MFTMirr : 19494 MB 1
Ordinary : 20322 MB 1745
You might resize at 15328641024 bytes or 15329 MB (freeing 11650 MB).
Please make a test run using both the -n and -s options before real resizing!
grow file system to fill the partition 00:00:04 ( SUCCESS )
run simulation 00:00:03 ( SUCCESS )
ntfsresize -P --force /dev/hda3 --no-action
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 26978910720 bytes (26979 MB)
Current device size: 38987827200 bytes (38988 MB)
New volume size : 38987821568 bytes (38988 MB)
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15329 MB (56.8%)
Collecting resizing constraints ...
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 ...
The read-only test run ended successfully.
real resize 00:00:01 ( SUCCESS )
ntfsresize -P --force /dev/hda3
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 26978910720 bytes (26979 MB)
Current device size: 38987827200 bytes (38988 MB)
New volume size : 38987821568 bytes (38988 MB)
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15329 MB (56.8%)
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])? 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/hda3'.
calculate new size and position of /dev/hda3 00:00:01 ( SUCCESS )
requested start: 103603185
requested end: 156296384
requested size: 52693200 (25.13 GiB)
new start: 103603185
new end: 156296384
new size: 52693200 (25.13 GiB)
check file system on /dev/hda3 for errors and (if possible) fix them 00:00:01 ( SUCCESS )
ntfsresize -P -i -f -v /dev/hda3
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 38987821568 bytes (38988 MB)
Current device size: 38987827200 bytes (38988 MB)
Checking for bad sectors ...
Checking filesystem consistency ...
Accounting clusters ...
Space in use : 15330 MB (39.3%)
Collecting resizing constraints ...
Estimating smallest shrunken size supported ...
File feature Last used at By inode
$MFT : 21893 MB 0
Multi-Record : 19477 MB 416
$MFTMirr : 19494 MB 1
Ordinary : 20322 MB 1745
You might resize at 15329005568 bytes or 15330 MB (freeing 23658 MB).
Please make a test run using both the -n and -s options before real resizing!
move file system to the right 01:06:48 ( SUCCESS )
perform read-only test 00:20:23 ( SUCCESS )
using internal algorithm
read 52693200 sectors
finding optimal blocksize
read 65536 sectors using a blocksize of 128 sectors 00:00:03 ( SUCCESS )
65536 of 65536 read
3.27186 seconds
read 65536 sectors using a blocksize of 256 sectors 00:00:03 ( SUCCESS )
65536 of 65536 read
2.87146 seconds
read 65536 sectors using a blocksize of 512 sectors 00:00:02 ( SUCCESS )
65536 of 65536 read
2.20214 seconds
read 65536 sectors using a blocksize of 1024 sectors 00:00:02 ( SUCCESS )
65536 of 65536 read
2.24713 seconds
read 65536 sectors using a blocksize of 2048 sectors 00:00:03 ( SUCCESS )
65536 of 65536 read
2.57334 seconds
read 65536 sectors using a blocksize of 4096 sectors 00:00:03 ( SUCCESS )
65536 of 65536 read
2.72122 seconds
read 65536 sectors using a blocksize of 8192 sectors 00:00:02 ( SUCCESS )
65536 of 65536 read
2.37375 seconds
read 65536 sectors using a blocksize of 16384 sectors 00:00:02 ( SUCCESS )
65536 of 65536 read
2.2495 seconds
read 65536 sectors using a blocksize of 32768 sectors 00:00:02 ( SUCCESS )
65536 of 65536 read
1.91634 seconds
read 65536 sectors using a blocksize of 65536 sectors 00:00:02 ( SUCCESS )
65536 of 65536 read
1.87684 seconds
optimal blocksize is 65536 sectors (32.00 MiB)
read 52037840 sectors using a blocksize of 65536 sectors 00:19:59 ( SUCCESS )
52037840 of 52037840 read
52693200 sectors read
perform real move 00:46:25 ( SUCCESS )
using internal algorithm
copy 52693200 sectors
finding optimal blocksize
copy 65536 sectors using a blocksize of 64 sectors 00:00:07 ( SUCCESS )
65536 of 65536 copied
7.43551 seconds
copy 65536 sectors using a blocksize of 128 sectors 00:00:07 ( SUCCESS )
65536 of 65536 copied
6.69612 seconds
copy 65536 sectors using a blocksize of 256 sectors 00:00:07 ( SUCCESS )
65536 of 65536 copied
7.02595 seconds
copy 65536 sectors using a blocksize of 512 sectors 00:00:07 ( SUCCESS )
65536 of 65536 copied
6.79999 seconds
copy 65536 sectors using a blocksize of 1024 sectors 00:00:07 ( SUCCESS )
65536 of 65536 copied
7.04899 seconds
copy 65536 sectors using a blocksize of 2048 sectors 00:00:06 ( SUCCESS )
65536 of 65536 copied
5.87084 seconds
copy 65536 sectors using a blocksize of 4096 sectors 00:00:05 ( SUCCESS )
65536 of 65536 copied
5.48953 seconds
copy 65536 sectors using a blocksize of 8192 sectors 00:00:06 ( SUCCESS )
65536 of 65536 copied
5.32998 seconds
copy 65536 sectors using a blocksize of 16384 sectors 00:00:04 ( SUCCESS )
65536 of 65536 copied
4.66536 seconds
copy 65536 sectors using a blocksize of 32768 sectors 00:00:05 ( SUCCESS )
65536 of 65536 copied
4.30795 seconds
copy 65536 sectors using a blocksize of 65536 sectors 00:00:04 ( SUCCESS )
65536 of 65536 copied
4.05939 seconds
optimal blocksize is 65536 sectors (32.00 MiB)
copy 51972304 sectors using a blocksize of 65536 sectors 00:45:20 ( SUCCESS )
51972304 of 51972304 copied
52693200 sectors copied
move partition to the right 00:00:01 ( SUCCESS )
old start: 80148285
old end: 132841484
old size: 52693200 (25.13 GiB)
new start: 103603185
new end: 156296384
new size: 52693200 (25.13 GiB)
update boot sector of ntfs file system on /dev/hda3 00:00:00 ( SUCCESS )
check file system on /dev/hda3 for errors and (if possible) fix them 00:00:01 ( ERROR )
ntfsresize -P -i -f -v /dev/hda3
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name : /dev/hda3
NTFS volume version: 3.1
Cluster size : 4096 bytes
Current volume size: 38987821568 bytes (38988 MB)
Current device size: 26978918400 bytes (26979 MB)
ERROR: Current NTFS volume size is bigger than the device size!
Corrupt partition table or incorrect device partitioning?
libparted messages ( INFO )
The kernel was unable to re-read the partition table on /dev/hda (Device or resource busy). This means Linux won't know anything about the modifications you made until you reboot. You should reboot your computer before doing anything with /dev/hda.
========================================
Grow /dev/hda2 from 35.09 GiB to 46.28 GiB
========================================
OUTPUT OF REQUESTED fdisk -l -u and parted
Disk /dev/hda 80.0 GB 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders, total 156301488 sectors
Units + sectors of 1 * 512 = 512 bytes
Disk identifier: 0x34fe34fd
Device Boot Start End Blocks Id System
/dev/hda1 63 6554519 3277228+ 12 Compaq diagnostics
/dev/hda2 * 654520 80148284 36796882+ 7 HPFS/NTFS
/dev/hda3 103603185 156296384 26346600 7 HPFS/NTFS