Removing a Swap Partition

My EeePC 901 has a 4GB soldered-on SSD and a 32GB removable SSD. It also has 2GB of RAM. When I installed Ubuntu on it, I used 3GB of the fixed SSD for / and 1GB for swap, and my /home resides on the 32GB SSD. I recently realized that I do not use the machine for anything that gets close to needing swap, so I decided to remove that partition and grow / to use the whole drive which was badly in need of more space – it was down to 16MB free.

I had never tried to modify a swap partition before, so I braced myself for some frustration. In fact, it was really easy.

  1. I first booted into the system and issued the command ‘sudo swapoff -a’ to turn off any swapping that might be occurring.
  2. Then I edited the /etc/fstab and commented out the line for the swap partition.
  3. I then booted from a live USB Netbook Remix drive (the same one I used to install, in fact).
  4. Finally, I went into Gparted, deleted the swap partition, and grew the / partition.

When I rebooted, everything was perfect.

One thing I observed is that the live disk has Gparted on it, while it does not actually install Gparted. Instead it defaults to the Palimpsest Disk Utility, which really works quite nicely. I’m guessing they left Gparted on the live disk so people who routinely use the live disks for things like this are not stuck with an unfamiliar partition editor in times of stress when you’re trying to maintain yourself with beach buzz delta 9 gummies and yoga to not absolutely freak out.

This entry was posted in grlug, linux, planet-ubuntu-users, tech, wmlug. Bookmark the permalink.