How do I add swap space to Ubuntu?
Answer
Perform the steps below to add swap space on Ubuntu 18.04.
Answer
Perform the steps below to add swap space on Ubuntu 18.04.
- Start by creating a file which will be used for swap: sudo fallocate -l 1G /swapfile. …
- Only the root user should be able to write and read the swap file. …
- Use the mkswap utility to set up a Linux swap area on the file: sudo mkswap /swapfile.