After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 497925 - Does not detect partitions on 8G iPod Nano
Does not detect partitions on 8G iPod Nano
Status: RESOLVED FIXED
Product: gparted
Classification: Other
Component: application
0.2.5
Other All
: Normal normal
: ---
Assigned To: gparted maintainers alias
gparted maintainers alias
Depends on:
Blocks:
 
 
Reported: 2007-11-18 15:43 UTC by Jamin W. Collins
Modified: 2010-07-01 18:48 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jamin W. Collins 2007-11-18 15:43:42 UTC
Please describe the problem:
gparted reports that /dev/sde (the 8G iPod Nano) has 1.88 GiB of unallocated space with no partitions of any kind.

Part (or all) of this is probably due to gparted assuming a sector size of 512 instead of the actual sector size of 2048.  As you can see from the following fdisk output for the same device, the sector size should be 2048 and there are indeed two partitions.

$ sudo fdisk -l /dev/sde
Note: sector size is 2048 (not 512)

Disk /dev/sde: 8120 MB, 8120172544 bytes
250 heads, 62 sectors/track, 255 cylinders
Units = cylinders of 15500 * 2048 = 31744000 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sde1               1           3       92876    0  Empty
/dev/sde2               4         255     7812000    b  W95 FAT32


Steps to reproduce:
1. Connect 8G iPod Nano
2. Start gparted
3. select the iPod device


Actual results:
gparted reports no partitions and the entire device as free space with only 1/4 the expected size for the whole device.

Expected results:
gparted to show the correct size and the existing partitions

Does this happen every time?
yes

Other information:
Comment 1 Curtis Gedak 2009-01-07 22:08:49 UTC
GParted uses the library libparted for many of the partition operations.

Would you be able run and post the results of the following command?

     parted /dev/DEVICE print unit s print unit chs print

     Where:  DEVICE is the name of your hard disk device (e.g., sda1)

This will help to isolate if the problem is with GParted or libparted.
Comment 2 Curtis Gedak 2009-01-07 22:11:12 UTC
Oops, my mistake.  The DEVICE example should have been "sda" not "sda1".

In the original bug report, I can see that the device was /dev/sde.  So the command would be:

     sudo parted /dev/sde print unit s print unit chs print
Comment 3 Jamin W. Collins 2009-01-07 23:28:37 UTC
sudo parted /dev/sdb print unit s print unit chs print
Warning: Device /dev/sdb has a logical sector size of 2048.  Not all parts of
GNU Parted support this at the moment, and the working code is HIGHLY
EXPERIMENTAL.

Error: Can't have a partition outside the disk!
Comment 4 Curtis Gedak 2009-01-07 23:41:16 UTC
Thank you for the quick response.

It looks like this problem is in the libparted library of the Parted project (lack of support for sector sizes greater than 512 bytes).

From searching the mailing lists for Parted, I can see that this item has been discussed in the past.  However, I did not observe a bug report for it on the Parted web site.

Would you be able to open a bug report for this on the Parted web site, and then report back here with a link to the bug you opened?

Parted Bug Reporting Link:
http://www.gnu.org/software/parted/bugs.shtml
Comment 6 Curtis Gedak 2010-03-05 21:04:16 UTC
Currently I am working to add support to GParted for sector sizes > 512 bytes.

Would you be able to provide the output of the following command for your iPod?

     sudo fdisk -l -u /dev/sde

Assuming that your iPod device path is still /dev/sde.
Comment 7 Jamin W. Collins 2010-03-05 21:41:11 UTC
Here you go:

$ sudo fdisk -l -u /dev/sdc
Note: sector size is 2048 (not 512)

Disk /dev/sdc: 8120 MB, 8120172544 bytes
206 heads, 22 sectors/track, 874 cylinders, total 3964928 sectors
Units = sectors of 1 * 2048 = 2048 bytes
Disk identifier: 0x20202020

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1              63       48194       96264    0  Empty
Partition 1 has different physical/logical beginnings (non-Linux?):
     phys=(0, 1, 1) logical=(0, 2, 20)
Partition 1 has different physical/logical endings:
     phys=(2, 254, 63) logical=(10, 130, 15)
Partition 1 does not end on cylinder boundary.
/dev/sdc2           48195     3964926     7833464    b  W95 FAT32
Partition 2 has different physical/logical beginnings (non-Linux?):
     phys=(3, 0, 1) logical=(10, 130, 16)
Partition 2 has different physical/logical endings:
     phys=(246, 205, 22) logical=(874, 179, 21)
Comment 8 Curtis Gedak 2010-06-01 21:43:48 UTC
Jamin, would you be able to test your problem with gparted-0.6.0-beta1?

Several enhancements have been committed to the git repository to support
devices with sector sizes larger than 512 bytes, and also to add a partition alignment option to "align to MiB".

A forum post has been created seeking help with testing:
http://gparted-forum.surf4.info/viewtopic.php?id=14135

It would be useful to retry the following parted command with parted version 2.2.

     parted /dev/DEVICE print unit s

     Where:  DEVICE is the name of your hard disk device (e.g., sda)
Comment 9 Curtis Gedak 2010-06-18 16:49:55 UTC
Jamin, GParted 0.6.0 has just been released.  This new version includes support for devices with sector sizes greater than 512 bytes.

Would you be able to try this latest release and answer the questions in comment #8?

This bug report will be closed if there is no response in the next few weeks.
Comment 10 Curtis Gedak 2010-07-01 16:39:47 UTC
Closing this bug report as there has been no response.

Since this iPod device used 2048 byte sectors, and since support for sector sizes greater than 512 bytes was added in GParted 0.6.0, I will mark this bug as resolved - fixed.

If this problem is not resolved, please feel free to re-open this bug report and provide additional details.
Comment 11 Jamin W. Collins 2010-07-01 18:43:35 UTC
$ sudo parted /dev/sdg print unit s
Warning: Device /dev/sdg has a logical sector size of 2048.  Not all parts of
GNU Parted support this at the moment, and the working code is HIGHLY
EXPERIMENTAL.

Model: Apple iPod (scsi)
Disk /dev/sdg: 8120MB
Sector size (logical/physical): 2048B/2048B
Partition Table: msdos

Number  Start   End     Size    Type     File system  Flags
 2      98.7MB  8120MB  8021MB  primary

Also, gparted does appear to report it correctly.
Comment 12 Curtis Gedak 2010-07-01 18:48:49 UTC
GParted uses libparted for initial file system detection.  If parted fails to recognize the file system then additional tools, such as blkid, are used to determine the file system type.

Since "gparted does appear to report it correctly" this bug report can remain closed.

For better support in command line parted you might wish to report the problem of HFS/HFS+ detection to the Parted project mailing list at bug-parted@gnu.org.