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

I have a situation where I need to expand my Linux partition to a partition that is available above it.

I would like to use unallocated 93.31 GiB to expand /dev/sda5.

I'd appreciate any help.

Here is the screenshot to give you an overview of partitions. enter image description here


share|improve this question

migrated from Jan 27 '13 at 7:38

This question came from our site for system and network administrators.

up vote 2 down vote accepted

Partition /dev/sda4 is basically a holder for all the space allocated for an extended partition. Partitions sd5..sdn are allocated from this space. This was implemented a long time ago so that larger disks with more than four partitions could be accomodated. Thus your problem is to expand the expanded partition pool (sda4) and then you can expand the subpartitions. Since you are including an area ABOVE you'll be unable to save the partition data in the subpartitions.

Your question is YES you can expanded the extended partition, using the following process:

 0. remove /dev/sda5 and /dev/sda6 from /etc/fstab and reboot system
 1. delete /dev/sda6  
 2. delete /dev/sda5 (yes you will lose the filesystetm and information so backup)
 3. delete /dev/sda4
 4. Recreate /dev/sda4 with all the available disk including the currently unused space.
 5. recreate /dev/sda5 with the size that you want
 6. recreate /dev/sda6 with the size that you want and mark as swap
 7. reboot the system
 8. do mkswap on /dev/sda6
 9. mkfs -t ext3 on /dev/sda5
 10. mount /dev/sda5
 11. restore backup onto /dev/sda5
 11a. return /etc/fstab to include /dev/sda5 and /dev/sda6
 12. reboot the system to see if all works

That is what you need to do.

share|improve this answer

Click the Resize/Move button, which appears as an arrow pointing rightward at a vertical line. Then drag the partition to the left to use up the unallocated space. Then drag the right edge of the partition right to use up the entire space. Apply your changes and go have lunch.

share|improve this answer
I cannot Resize/Move /dev/sda5 or /dev/sda4. The button is not active for them – Moiz Jan 27 '13 at 4:11

You must log in to answer this question.

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