1

Topic: Will my resize of disk be canceled?

I started resizing a 3.64 TiB partition, filled with hardlinks and mostly empty space, down to 1.27 TiB six days ago. After letting the operation run for about a day I hit cancel, when I noticed resize2fs was taking forever to update inode references. Though, I didn't hit force cancel. Once resize2fs finishes updating the inode references will gparted undo the entire disk shrink? (would prefer to keep the shrink)

2

Re: Will my resize of disk be canceled?

Which version of GParted are you running?

3

Re: Will my resize of disk be canceled?

0.31

4

Re: Will my resize of disk be canceled?

If I recall correctly, newer versions will permit the current operation to complete as long as the "Force Cancel" button is not clicked.  I think any remaining operations are not started.

5

Re: Will my resize of disk be canceled?

Thanks. After letting resize2fs finish is there anything I should do to make sure the file system is setup properly. I'd rather avoid any more manipulation of this partition, since it looks like it's going to take about 2 weeks to finish the shrink operation.

6

Re: Will my resize of disk be canceled?

If the hard drive is attached via a USB interface then that could explain why the process is so slow.

7

Re: Will my resize of disk be canceled?

gedakc wrote:

If the hard drive is attached via a USB interface then that could explain why the process is so slow.

Yeah, it's attached via USB 3.0, and I believe the partition might not be aligned properly. A few years back, I was misinformed with modern HDDs needing to be aligned by cylinder. Going to be fixing that on all of my HDDs. If I can get rid of some of the hardlinks (have some folders ready for deletion) should that speed up future inode reference updates?

8

Re: Will my resize of disk be canceled?

For a physical spinning Hard Disk Drive (HDD) I have not found it worth the effort to migrate from Cylinder Alignment to MiB alignment.  However with Solid State Drives (SSD) this can certainly be worth while and can reduce the wear and tear on the drive.

As far as I know the main reason the resize is taking so long is because the operations are being run over the USB bus.  USB is very slow compared to the SATA connection available via the motherboard on Desktop computers.

9

Re: Will my resize of disk be canceled?

But, aren't USB 3.0 and SATA III within 100 MB of each other in terms of transfer speed? I'm sure that difference would have an impact. Wouldn't having a ton of hard links on the disk increase the time to update inode references, or is it just from shrinking the same number of inodes to fit in a smaller space that's taking so long?

10

Re: Will my resize of disk be canceled?

I can only speak from my personal experience in which data access over USB has been orders of magnitude slower than SATA.

11

Re: Will my resize of disk be canceled?

Well, the resize finally finished. I noticed that even though the disk isn't mounted gparted still shows the disk as having a mount point. Could it be the fact it's set up to mount as soon as an operation writes to the disk that caused it to take so long?

Here's what I have in my fstab:

UUID=95cf23fa-0be9-465c-8b63-e35e7e97b8f5    /mnt/ArchBackup    ext4    rw,noatime,data=ordered,noauto,x-systemd.device-timout=1,nofail 0 2

12

Re: Will my resize of disk be canceled?

GParted reads mount points from /etc/fstab for file systems that are not currently mounted so this is consistent with what you observed.