1 (edited by hanman 2009-12-22 19:26:56)

Topic: SOLVED: Current NTFS volume size is bigger than the device size!

Ok so I got the same old problem.. The partion not working now is sdb1.. rest is unallocated.
Gparted 0.4.8 Im using Knoppix 6.2 from USB flash drive. This is my 3rd day using a Unix-like OS; I'm using this because im trying to fix my Windows, so be patient with me if I don't understand something.. :S The drive in question is an external HDD, no OS installed, just for storing files. I tried to resize the ntfs partition.

GParted:

file system: ntfs
size: 833.86 GiB
Flags:

Path: /dev/sdb1
Status: Not mounted
Label: Timo_HDD
UUID: 0CC0CD4BC0CD3BA8

First sector: 63
Last sector 1748723444
Total sectors: 1748723382

! Warning
ntfsresize v2.0.0 (libntfs 10:0:0)
Device name  : /dev/sdb1
NTFS volume version: 3.1
Cluster size  : 4096 bytes
Current volume size : 1000202236416 bytes (1000203 MB)
Current device size: 895346371584 bytes (895347 MB)
ERROR: Current NTFS volume size is bigger than the device size!
Corrupt partition table or incorrect device partitioning?

Unable to read the contents of this file system!
Because of this some operations may be unavailable.

fdisk:

Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0xe8900690

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1              63  1748723444   874361691    7  HPFS/NTFS

parted:

Model: WD 10EADS External (scsi)
Disk /dev/sdb: 1953525168s
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start  End          Size         Type     File system  Flags
 1      63s    1748723444s  1748723382s  primary  ntfs

PBR: http://www.mediafire.com/download.php?myi5yh5keig
MBR: http://www.mediafire.com/download.php?wzewzyqmynz

2

Re: SOLVED: Current NTFS volume size is bigger than the device size!

From looking at the sdb1-hanman.pbr file, I was unable to find an NTFS marker to indicate that this is the partition boot record.

Based on the output from fdisk and parted, the following command should capture the NTFS partition boot record in a file.

NOTE:  Be extra careful to type this command in properly, otherwise loss of data could result.

dd if=/dev/sdb of=sdb1-hanman-2ndtry.pbr bs=512 count=1 skip=63

where sdb1-hanman-2ndtry.pbr is the name of the file that will need to be uploaded.

3

Re: SOLVED: Current NTFS volume size is bigger than the device size!

2nd try: http://www.mediafire.com/download.php?4jkyymqrg1i

4

Re: SOLVED: Current NTFS volume size is bigger than the device size!

We will decrease the NTFS volume size to fit within the partition.

The change I have made to the file is from a length of 1,953,519,992 sectors:
00000020   00 00 00 00  80 00 80 00  78 59 70 74  00 00 00 00
To a new length of 1,748,723,381  sectors:
00000020   00 00 00 00  80 00 80 00  B5 66 3B 68  00 00 00 00

Note:  The NTFS volume size is always 1 sector less than the total number of sectors in the partition table entry because the NTFS backup sector is not considered part of the NTFS volume.

To apply this change:

1) Download the new NTFS PBR: sdb1-hanman-2ndtry_new.pbr

2) Load the new NTFS PBR on your hard disk.
NOTE:  Be extra careful when entering the commands.  Data loss could result otherwise.

dd if=sdb1-hanman-2ndtry_new.pbr of=/dev/sdb bs=512 count=1 seek=63

3) Reboot the computer

4) Check that the file system is recognized in GParted

5) If all seems fine then I would advise booting into Windows and running "chkdsk /f /r" multiple times, until there are no more faults.

5

Re: SOLVED: Current NTFS volume size is bigger than the device size!

Thanks gedakc! It worked.

6

Re: SOLVED: Current NTFS volume size is bigger than the device size!

That's great to hear.  smile

Thanks for editing your initial post and prefixing the title with SOLVED.