How to Increase SWAP memory in Ubuntu

If you are facing issue with multi processing task in your Ubuntu system and system showing your Swap memory full. You can simply increase the Swap memory by running some commands in command terminal

sudo swapoff -a

when you run this command, system asked you to enter password, enter yo system login password. after that you can run these commands.

sudo dd if=/dev/zero of=/swapfile bs=1M count=3000
sudo mkswap /swapfile
sudo swapon /swapfile

Now your Swap memory size increase with 3GB

Was this post helpful?
Let us know if you liked the post. That’s the only way we can improve.
Harinder Singh

Harinder Singh

My name is Harinder Singh and I specialize in Software industry. I consider myself as a life learner. I love learning new concepts, embracing new ideas and reading and searching for innovation.