Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Straight forward, as the title says but, I've never moved a partition with GParted and I'm concerned that I will damage the drive. I have a screen shot.

Gparted screenshot

I'm trying to get the sda2 partition to use the unallocated space. I believe that I have to move sda2 to the end of the hard drive but, I'm not sure and I don't know how.

Any help would be appreciated!

share|improve this question
Do you want to resize sda2 to just 218 GB, or to entire 363 GB? – grawity Oct 18 '12 at 19:25
@grawity the entire 363. – tijko Oct 18 '12 at 19:27
up vote 3 down vote accepted

Partitions must be contiguous (you cannot use two separate disk areas for a single /dev/sda2), so you will first need to move sda3 to the end of the disk, using GParted's "Move/resize" function.

|1|------sda2------|           free space           |-----------sda3-----------|

Afterwards, use the same function to expand sda2 into the free space in the middle:


However, since sda3 is your system partition, you cannot move or resize it from the same system. You will have to boot from the Ubuntu CD instead.

Moving (or, in rare cases, resizing) partitions can cause all files to be lost – for example, if the power goes out during moving (it takes a long time to move a partition). It never causes physical damage, however.

share|improve this answer
Thanks for the reply grawity, I was worried that this would be what I have to do. I'm thinking grub will be damaged in the process too, right? – tijko Oct 18 '12 at 19:57
@tijko: If it's in sda1, then it should remain untouched... but yes, there's a chance you'll need to reinstall it using the CD. – grawity Oct 18 '12 at 22:39
my concerns up ended up being unfounded :) I was getting a mixed up with how to use GParted but, in the end Gparted couldn't have been more straight-forward. I had been thinking I needed to specify numerically where I wanted to place sda2, when all it came down to was to slide sda3 to the right. – tijko Oct 19 '12 at 9:42

grawity's answer is not entirely complete for this question. It is possible to move the contents of partition 2 to the end of the device. Simply right-click and copy the partition, and paste it at the end. After that succeeds, delete partition 2.

It will cause partition 2 and partition 3 to switch in naming. After moving sda2 to the end of the device- sda3 will be renamed to sda2, and sda2 renamed to sda3.

You will need inform the system of this change. If sda2 or sda3 are referenced in /etc/fstab, then you will need to change any references of sda2 to sda3 and sda3 to sda2. Also, you will have to reinstall the Grub bootloader so it knows about the changes.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .