0

When I installed Arch linux I created a 24G swap partition. Now I want to delete it and merge it with home partition. How to do it?

Device          Start        End    Sectors   Size Type
/dev/sda1        2048     821247     819200   400M Windows recovery environment
/dev/sda2      821248    1353727     532480   260M EFI System
/dev/sda3     1353728    1615871     262144   128M Microsoft reserved
/dev/sda4     1615872 1694668799 1693052928 807.3G Microsoft basic data
/dev/sda5  1694668800 1744998399   50329600    24G Microsoft basic data SWAP
/dev/sda6  1745000448 1786943487   41943040    20G Microsoft basic data
/dev/sda7  1786943488 1899671551  112728064  53.8G Microsoft basic data HOME
/dev/sda8  1899673600 1900595199     921600   450M Windows recovery environment
/dev/sda9  1900595200 1953513471   52918272  25.2G Microsoft basic data
0

Well the only way I can think of might take a long time to process:

  1. First delete your swap partition using Gparted or sth alike.

  2. The space that was allocated to it is now free, but you can't just attach it to your HOME partition because they're separated by your root partition sda6.
    In order to allocate your /home more space, you have to free the adjacent space (you can't simply overwrite another partition), so the thing here is to move the next partition (sda6) to fill the space you just freed from sda5.
    If you use Gparted, you have to use the Resize/Move dialog:

Gparted dialog

Type 0 in the Free space preceding box and the Free space following box will increase by itself. 3. Finally extend your home partition to fill the aformentioned free space:
In the Resize/Move dialog just increase the New Size box to the maximum.

  1. Click the check button on the main interface and operations will be performed.

  2. Go make yourself a coffe, a tea, take a nap or something because it might take a while :)

  3. In terminal, run sudo update-grub to make Grub aware of the changes, else your computer might not boot at all, which is not cool at all.

If you don't use Gparted, I guess what you use's interface would look a bit like Gparted's so you would just have to find the equivalent stuff. :)

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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