I want to merge an unallocated space with my Ubuntu Partition but i can't
Solution 1:
Make sure that you have a good backup of your important Ubuntu files, as this procedure can corrupt or lose data.
Keep these things in mind:
-
always start the entire procedure with issuing a swapoff on any mounted swap partitions, and end the entire procedure with issuing a swapon on that same swap partition
-
a move is done by pointing the mouse pointer at the center of a partition and dragging it left/right with the hand cursor
-
a resize is done by dragging the left/right side of a partition to the left/right with the directional arrow cursor
-
if any partition can't be moved/resized graphically, you may have to manually enter the specific required numeric data (don't do this unless I instruct you to)
-
you begin any move/resize by right-clicking on the partition in the lower pane of the main window, and selecting the desired action from the popup menu, then finishing that action in the new move/resize window
Do the following...
Note: if the procedure doesn't work exactly as I outline, STOP immediately and DO NOT continue.
- boot to a Ubuntu Live DVD/USB, in “Try Ubuntu” mode
- start
gparted
- if you don't need /dev/sda5 then delete this partition (there is data on it)
- if you don't need /dev/sda7 then delete this partition (there is data on it)
- move /dev/sda6 partition all the way left
- resize the right side of /dev/sda6 partition all the way right
- click the Apply icon
Solution 2:
It is not trivial to make sda6
use the free space, because it comes before that partition rather than after it. A move of sda6
is therefore required. This can be a lengthy process that may fail.
Take following steps from a live session so none of the partitions on the drive are in use. Do not start this before your backup of your user data is up to date. When manipulating partitions, there is always a risk (human error and/or technical error).
- Remove partition
sda5
; - Remove partition
sda7
; - Move your current system partition sda6 to the left into the free space. This will take a very long time and may fail;
- Enlarge the moved
sda6
to the right to fill the free space.
A safer and quicker option would be to create a new partition in the free space (after removing /dev/sda5
and 7
). If you then move out all your user data from system partition /dev/sda6 to that new partition, it will have plenty of free space. This can be done from within your running Ubuntu system.