nilfs-dev / nilfs-utils

NILFS utilities
https://nilfs.sourceforge.io/
Other
46 stars 6 forks source link

Can't really shrink the partition using nilfs-resize (Error: couldn't move any segments. Aborted.) #8

Closed Harvie closed 7 months ago

Harvie commented 7 years ago

I have NILFS2 partiton that was previously full of data, but i freed up most of space and cleaned old checkpoints. Now it reports only 2% used:

/dev/loop0 992M 16M 912M 2% /tmp/NILTEST

But when i try to resize it (even just from 990M to 900M) it says it can't move any segments:

# nilfs-resize /dev/loop0 900M
Partition size = 1572864000 bytes.
Shrink the filesystem size from 1048576000 bytes to 943718400 bytes.
12 segments will be truncated from segnum 112.
Do you wish to proceed (y/N)? y
Error: couldn't move any segments.
Aborted.

it's nilfs-resize version 2.2.6

konis commented 7 months ago

v2.2.10 util release fixes issue with shrinking filesystems that are near empty or contain empty segments created by rollforward recovery.