1 (edited by gedakc 2010-01-09 18:47:34)

Topic: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Hi, I too am suffering from the NTFS volume size bug.  Can you assist me with a fix?  I am unsure exactly when my system was impacted.  It may have been a resizing action, but I am unsure.  Here is the output of fdisk -l -u and below that are links to my PBR and MBR backups. 

Many thanks in advance!!

======================================================
Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0xabe52ce9

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      206847      102400    7  HPFS/NTFS
Partition 1 does not end on cylinder boundary.
/dev/sda2          206848   163637247    81715200    7  HPFS/NTFS
/dev/sda3       163638216   202692103    19526944   83  Linux
/dev/sda4       202692105   488408129   142858012+   f  W95 Ext'd (LBA)
/dev/sda5       281041173   320095124    19526976   83  Linux
/dev/sda6       320095188   323998899     1951856   82  Linux swap / Solaris
/dev/sda7       323998983   488392062    82196540   83  Linux

Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
Units = sectors of 1 * 512 = 512 bytes
Disk identifier: 0x7d62e2e7

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *        2048   153602047    76800000    7  HPFS/NTFS
/dev/sdb2       153602048   312575999    79486976    7  HPFS/NTFS
======================================================

SDA1 PBR File:  http://dl.dropbox.com/u/118491/sda1-jmm.pbr **** UPDATED ***
SDA2 File:  http://dl.dropbox.com/u/118491/sda2-jmm.pbr
MBR File:  http://dl.dropbox.com/u/118491/sda-jmm.mbr

2

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Is it the first partition (sda1) that is experiencing the problem?

Which version of GParted are you using?

Would you be able to upload your files to a different sharing site?

When I try to download the files I kept getting the following message:
Currently a lot of users are downloading files. Please try again in 2 minutes or become a Premium member

And after several tries received this message:
Unfortunately right now our servers are overloaded and we have no more download slots left for non-members. Of course you can also try again later.

3 (edited by jmcturnan 2010-01-05 20:37:49)

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

sda2 is more likely the problem -  my install of Windows7 lives in there.  sda1 is the goofy 100mb partition that Windows7 creates for some reason.  I am/was using version gparted 04.8-1  -- Until there is a fix I'll use 4.6.

I have moved the files to a new hosting location - hopefully they will work for you this time... here are the new links:

SDA1 PBR File:  http://dl.dropbox.com/u/118491/sda1-jmm.pbr **** UPDATED ***
SDA2 PBR File:  http://dl.dropbox.com/u/118491/sda2-jmm.pbr
MBR File:  http://dl.dropbox.com/u/118491/sda-jmm.mbr

Thanks for your help.

John

gedakc wrote:

Is it the first partition (sda1) that is experiencing the problem?

Which version of GParted are you using?

Would you be able to upload your files to a different sharing site?

When I try to download the files I kept getting the following message:
Currently a lot of users are downloading files. Please try again in 2 minutes or become a Premium member

And after several tries received this message:
Unfortunately right now our servers are overloaded and we have no more download slots left for non-members. Of course you can also try again later.

4

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

If the problem is with sda2, then we will need the NTFS partition boot record from the sda2 partition which starts at sector 206848.

You can capture the NTFS Partition Boot Record in a file with the following command:

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

dd if=/dev/sda of=sda2-jmm.pbr bs=512 count=1 skip=206848

where sda2-jmm.pbr is the name of the file that will need to be uploaded.

5 (edited by jmcturnan 2010-01-05 20:37:27)

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Well, the primary problem is that Gparted of any version will not recognize any of the SDA partitions.  fdisk -lu says "Partition 1 [sda1] does not end on cylinder boundary."  I have attached the boot partition of sda2 in addition. 

Also, I noticed when I created the sda1 pbr file I used the incorrect parameters for the dd command.  I redid it just now using: "dd if=/dev/sda of=sda1-jmm.pbr bs=512 count=1 skip=2048"  which properly matches my fdisk output.

SDA1 PBR File:  http://dl.dropbox.com/u/118491/sda1-jmm.pbr **** UPDATED ***
SDA2 PBR File:  http://dl.dropbox.com/u/118491/sda2-jmm.pbr
SDA MBR File:  http://dl.dropbox.com/u/118491/sda-jmm.mbr


Thanks again,
John

gedakc wrote:

If the problem is with sda2, then we will need the NTFS partition boot record from the sda2 partition which starts at sector 206848.

You can capture the NTFS Partition Boot Record in a file with the following command:

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

dd if=/dev/sda of=sda2-jmm.pbr bs=512 count=1 skip=206848

where sda2-jmm.pbr is the name of the file that will need to be uploaded.

6

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Your first partition (sda1) looks fine.
204,800 sectors for partition size according to the MBR.
204,799 sectors for the NTFS volume size according to the NTFS PBR.

Your second partition (sda2) also looks fine.
163,430,400 sectors for partition size according to the MBR.
163,430,399 sectors for the NTFS volume size according to the NTFS PBR.

So, in conclusion, both of the NTFS file systems on disk device "sda" (250 GB) appear normal.

Perhaps you are experiencing a problem with the NTFS file systems on disk device "sdb" (160 GB)?

If so, then I will need the MBR, and PBR's from the "sdb" disk device.

7 (edited by jmcturnan 2010-01-06 03:15:34)

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Nope, sdb works great in gparted. 

Below is a link to a screenshot from gparted 4.8 taken Ubuntu 9.10 which is installed on sda7. 

As you can see gparted is unable to read the partitions.... it is listed as "unallocated" 

Also, doesn't the fdisk message "Partition 1 does not end on cylinder boundary." indicate that there is in fact a problem with sda1?  Note - booting from Gparted Live 4.6 gives the exact same results...."unallocated."


http://dl.dropbox.com/u/118491/Screenshot-1.png

8

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

I did some further research and tried running 'testdisk'  Here is the output, which is quite interesting:


http://dl.dropbox.com/u/118491/testdisk1.png

9

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

A picture is worth a thousand words.  smile
This looks like a completely different problem than the problem where "NTFS volume is bigger than device".

Can you try the following command and post the output from it?

parted /dev/sda unit s print

10

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

That will teach me to try to diagnose my own mbr problems smile ...the output is: 

"Error: Can't have a partition outside the disk!    "

gedakc wrote:

A picture is worth a thousand words.  smile
This looks like a completely different problem than the problem where "NTFS volume is bigger than device".

Can you try the following command and post the output from it?

parted /dev/sda unit s print

11

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

It would appear that the extended partition (sda4) reaches beyond the end of the physical disk.

488397168 sectors for total disk size.
488408129 sectors for the end of sda4 (extended partition).
488392062 sectors for the end of sda7 (the last logical partition inside the extended partition)

The extended partition (sda4) is obviously beyond the end of the disk.

Unfortunately parted and hence GParted cannot resolve this problem.
Fortunately, your last logical partition is within the physical size of the disk.

To fix this problem will likely require manually changing the end sector of the sda4 partition to be less than the total size of the disk, and larger than the end sector for sda7.
The GNU/Linux tool fdisk will permit you to do this from the command line.

12

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Thanks so much for your help!  Much appreciated.  I elected to backup and repartition the entire drive, rather than risk the adjusting fix via fdisk.  I've no idea why this problem occurred. But lets close this down as "Solved"

Regards,
John

13

Re: [SOLVED] - GParted NTFSResize/NTFS volume size bug

Thank you for reporting back with the solution you used.  I will edit the initial post to prefix the title with "SOLVED".