I need more space on my root partition running Ubuntu 17 (using Xfce session).
I do have a lot of unallocated space BEFORE.
However, when I try to resize root partition - /dev/sdb2 , I can't add/remove a MiB...

Is this even possible?

If so, can it somehow be done from the live system or do I have to use live CD/USB?

enter image description here

There is really just Ubuntu and Xcfe session, LUBUNTU_SYSTEM is just an old label :)

  • 2
    You cannot resize a mounted partition so you have to use a live session. Then you can first move your / partition to the beginning of your disk and then resize. I would recommend a backup before any operation on the partitions - one never knows ...
    – muclux
    Feb 2 '18 at 17:28
  • @muclux will the system and booting remain untouched? :)
    – jave.web
    Feb 2 '18 at 18:01
  • Well, as I said, better backup before. But normally all should go well, if you pay attention at what you are doing. Boot from Live DVD/USB, call gparted, move /dev/sdb2 to create an unallocated space behind it, and then resize /dev/sdb2. Don't mount your disk partitions during this operation.
    – muclux
    Feb 2 '18 at 18:16
  • @muclux Thank you, booting a linux live USB (Lubuntu Try Mode) and using GParted worked :) ... I think that I have read somewhere that in newer versions you can resize/move even when in the live system - is it impossible in this case because it is not just expanding to the right but also moving to the left?
    – jave.web
    Feb 2 '18 at 19:36
  • 1
    You can only grow to the right while it is mounted. Moving requires it to be unmounted. BTRFS can even shrink while it is mounted ;)
    – psusi
    Feb 2 '18 at 19:37

A partition can only be resized by modifying its end. Therefore first, you have to move the / partition to the beginning of the drive, gaining some free space after the moved / partition. Then you can grow the / partition which will be done by changing its end block number to a bigger number.

These actions can both be made through GParted, called from a live system on an USB or a DVD, but not from the current system where the partition is currently mounted.

Not the answer you're looking for? Browse other questions tagged or ask your own question.