[Techtalk] Repartitioning advice

David Sumbler david at aeolia.co.uk
Sun Mar 21 22:01:23 UTC 2021


> David Sumbler writes:
> > I would like to repartition the disk in a similar layout to my own
> > computers.  In other words, I want to shrink /dev/sda2 to, say
> 60Gb,
> > create a new partition of a similar size (eventually for v.20.02),
> and
> > use the remaining 800Gb as /home.  All that, of course, without
> losing
> > any data, and still being able to boot v.16.04.
> > 
> > What is the best software to use to do this, in a fairly foolproof
> way?
> 
> I usually use gparted for things like that, mostly because I don't
> trust myself not to mess things up using command-line partitioners
> like fdisk (even though I'm a heavy command-line user otherwise).
> 
> But fair warning: on big disks, resizing partitions with gparted can
> be extremely slow. I usually end up giving up after 3 hours or so,
> and deciding to do things some other way, like just restoring /home
> from a backup (of course you're making a backup before messing with
> the partition table, right?)
> 
> I'm not sure why resizing a partition should take many times longer
> than backing up with rsync then copying the whole backup, but it
> seems to. Maybe it's just gparted; I don't know if other
> partitioning programs are faster.
> 
> FWIW, I use the same partitioning scheme as you, with one partition
> for the OS I'm currently using, another for the last working one,
> and maybe one or two more in case I want to try some experimental
> distro, plus a swap partition, then the rest of the disk in a great
> big /home partition. I used to have a shared /boot partition, but
> grub2 doesn't deal well with that so I've given up on that.
> 
>         ...Akkana

Thanks for that advice.  I'll use gparted - I'm pretty sure I've used
that in the past, but it's so long since I did anything like this I
thought there might be something else worth trying.

It shouldn't be too difficult, and even if it takes a few hours that's
not likely to be a problem.  Fortunately my partner has only used about
4% of the disk, so it should be fairly straightforward to shrink the
main partition, add another similar one, make the rest of the drive one
big (extended) partition and then copy all the /home stuff into it.

Thanks again for your advice.

David




More information about the Techtalk mailing list