GNOME Bugzilla – Bug 670017
Corrupting swap partitions
Last modified: 2012-02-22 00:58:18 UTC
I'm using gparted-live-0.11.0-10.iso The main thing I use gparted for is aligning partitions in VMware virtual machines. For an 8GB drive Debian lenny and prior will create a single ext3 partition followed by an extended partition that contains a ~400MB swap partition and it would leave a few MB of free space at the end of the disk. My alignment procedure was: 1. Grow the extended partition to fill the drive 2. Move the swap partition as far to the end as it will go 3. Shrink the extended partition to be 1 MiB larger than the swap partition (more stuff to align the ext3 partition that isn't relevant here) This used to work fine, but with this version of the live CD if I do this then after step #2 the swap partition shows as unrecognized, like it has become corrupt. Since it's just a swap partition I can immediately reformat it as linux-swap and it works fine, but it didn't used to require this step.
Thank you Brad for reporting this problem. Using the steps you mentioned I have been able to confirm the problem. Swap space is a special case because GParted no longer copies the data, but instead is supported to recreate the swap space in the new location using the same label and UUID. Out of curiosity, what was the previous version you used that did work correctly?
I think the last one I used was 0.9.0-7
From checking the code I discovered that this regression was introduced in GParted version 0.11.0 by the following change: Bug #663980 - Avoid redundant file system maximize actions on copy, move, and resize A new enhancement to address this regression has been committed to the Gnome git repository for inclusion in the next release of GParted (0.12.0 on Feb 21, 2012). The relevant git commit can be viewed at the following link: Fix regression when shrinking, moving and copying swap (#670017) http://git.gnome.org/browse/gparted/commit/?id=93241cccbf4974a4a0ce4024cf94278f9ba3f386
Moving this bug report from livecd to application component since it will occur on any install of GParted 0.11.0.
This enhancement has been included in GParted 0.12.0 released on February, 21, 2012.