How Much Swap Space Do I Need Linux?
Contents Amount of System Ram Recommended Swap Space Less Than 2 Gb 2 Times the Amount of Ram 2 Gb – 8 Gb Equal to the Amount of Ram 8 Gb – 64 Gb 0.5 Times the...
| Amount of system RAM | Recommended swap space |
|---|---|
| less than 2 GB | 2 times the amount of RAM |
| 2 GB – 8 GB | Equal to the amount of RAM |
| 8 GB – 64 GB | 0.5 times the amount of RAM |
| more than 64 GB | workload dependent |
Do you need swap space Linux?
Having swap space is always a good thing. Such space is used to extend the amount of effective RAM on a system, as virtual memory for currently running programs. But you can’t just buy extra RAM and eliminate swap space. Linux moves infrequently used programs and data to swap space even if you have gigabytes of RAM..
Must Read
Does 16gb RAM need a swap partition?
If you have a large amount of RAM — 16 GB or so — and you don’t need hibernate but do need disk space, you could probably get away with a small 2 GB swap partition. Again, it really depends on how much memory your computer will actually use. But it’s a good idea to have some swap space just in case.