JRD wrote:If it's ok, I will try to ask about it when installing grub2.
Please consider that it is potentially dangerous and can easily destroy all the data on a volume.
I think you should:
- ensure there really is only one partition and a (for parted) valid MBR
- don't touch the end of the partition
- print output of parted <dev> unit s print
- Give a very BIG warning
- (give the user the possibility to backup his data and recommend it)
Now reading your message again: Do you only mean a help output suggesting how to do it manually?
JRD wrote:I think you could simply do it with gparted, which will also reduce the filesystem in the same time.
I found no way to address sectors with gparted.