Move Free Space From Primary to Logical Partition - How?

Forum rules
Before you post please read this
Post Reply
ardhill
Level 1
Level 1
Posts: 4
Joined: Sun Dec 16, 2018 5:43 am
Location: Northern Ireland

Move Free Space From Primary to Logical Partition - How?

Post by ardhill » Wed Jul 24, 2019 7:59 am

Hi, I need a little help with partitioning, please.

I have some free space that I got from shrinking a Windows partition and I want to add it to my Linux partition. The problem is that I can’t move the free space or re-size my Linux partition bigger - the options just aren’t available.

I assume this is because the free space is on a primary partition and Mint is on an Extended partition. How to make this happen is beyond my partitioning understanding, which is fairly basic. Any help with this, please?

Disks Partition Manager from USB live distro
Disks Partition Manager from USB live distro
-
Gparted from USB live distro
Gparted from USB live distro

See screenshots are of the same drive, just from two different partition tools - Disks and Gparted. Both taken from a Live Distro on USB.

The drive is a standard old HDD, not SSD.

Thanks.
Paul
Linux Mint Cinnamon

athi
Level 6
Level 6
Posts: 1459
Joined: Sun Mar 30, 2014 10:15 am
Location: USA

Re: Move Free Space From Primary to Logical Partition - How?

Post by athi » Wed Jul 24, 2019 8:27 am

Extended partitions are primary partitions that acts as containers for logical partitions. In order to expand the logical partitions, you will need to first expand the extended partition to subsume the free space. Then the free space will be available for use by the logical partitions.

From the layout of the partitions, in order for you to add the free space to the sda7 (/home) partition, you will have to expand sda4 (extended partition) left, expand sda5 (/) left, shrink sda5 right, expand sda6 (SWAP) left, shrink sda6 right, expand sda7 (/home) left. That is a lot of work for 11GB.
Mint Mate 19.1. Main rig is HP 800G2 I5 6500 16GB ram, 120GB boot drive, 2x3TB, 1x4TB data drives. Oldest rig is Mate 18.3 on Dell D620 with 32bits core duo.

ardhill
Level 1
Level 1
Posts: 4
Joined: Sun Dec 16, 2018 5:43 am
Location: Northern Ireland

Re: Move Free Space From Primary to Logical Partition - How?

Post by ardhill » Wed Jul 24, 2019 10:54 am

Thanks athi, but I can't get that to work.

When I select the extended partition sda4, it will only let me shrink it, not expand it. I tried in both Gparted and KDE Partition Manager.
Paul
Linux Mint Cinnamon

athi
Level 6
Level 6
Posts: 1459
Joined: Sun Mar 30, 2014 10:15 am
Location: USA

Re: Move Free Space From Primary to Logical Partition - How?

Post by athi » Wed Jul 24, 2019 11:05 am

ardhill wrote:
Wed Jul 24, 2019 10:54 am
Thanks athi, but I can't get that to work.

When I select the extended partition sda4, it will only let me shrink it, not expand it. I tried in both Gparted and KDE Partition Manager.
See if the following works for you, https://askubuntu.com/questions/536233/ ... th-gparted

Don't forget to backup your data before working on the partitions.
Mint Mate 19.1. Main rig is HP 800G2 I5 6500 16GB ram, 120GB boot drive, 2x3TB, 1x4TB data drives. Oldest rig is Mate 18.3 on Dell D620 with 32bits core duo.

ardhill
Level 1
Level 1
Posts: 4
Joined: Sun Dec 16, 2018 5:43 am
Location: Northern Ireland

Re: Move Free Space From Primary to Logical Partition - How?

Post by ardhill » Wed Jul 24, 2019 5:02 pm

As I said, Gparted just wouldn't let me expand the partition. I had a few Live distros on USB, so I popped another one in to see if the partition manager on that would show any more light on the problem. I Booted up Peppermint OS, and the partition manager was... Gparted. But, this time it gave me the option to 'expand' the partition. I was able to expand it, move the logical partitions along and expand the /home partition. :D

No idea why it worked with one version of Gparted and not another, but it's working now. Thanks for your input athi.
Paul
Linux Mint Cinnamon

gm10
Level 19
Level 19
Posts: 9213
Joined: Thu Jun 21, 2018 5:11 pm

Re: Move Free Space From Primary to Logical Partition - How?

Post by gm10 » Wed Jul 24, 2019 5:06 pm

You cannot modify mounted partitions. Unmount the swap partition (right click > swapoff) and you'll be good to go.
Tune up your LM 19.x: ppa:gm10/linuxmint-tools

ardhill
Level 1
Level 1
Posts: 4
Joined: Sun Dec 16, 2018 5:43 am
Location: Northern Ireland

Re: Move Free Space From Primary to Logical Partition - How?

Post by ardhill » Fri Jul 26, 2019 5:06 pm

Cheers gm10, turning swap off wasn't a problem, though I appreciate your input. The 'not being mounted' bit I did understand.

I can't figure out why I had a problem (i.e. the ability to expand simply wasn't an option), but it seems that I didn't have the same problem when I used a different live distro. Was it the distro, did I do something different - who knows :?
Paul
Linux Mint Cinnamon

gm10
Level 19
Level 19
Posts: 9213
Joined: Thu Jun 21, 2018 5:11 pm

Re: Move Free Space From Primary to Logical Partition - How?

Post by gm10 » Fri Jul 26, 2019 5:58 pm

Not all distros auto-mount existing swap space in the live environment.
Tune up your LM 19.x: ppa:gm10/linuxmint-tools

Post Reply

Return to “Mounting Partitions”