I have 8Gb usable memory and 10Gb swap space available

My memory usage is 90-95% used while only +/- 1gb swap space is used.

Do I misunderstand the purpose of swap space or is there some issue on my side?


  • Check my comment below. – user589808 Oct 5 '16 at 12:10
  • You want to avoid swap, not using more of it. Swap is a partition on your HDD or SSD. Any are slower than RAM. – user589808 Oct 5 '16 at 12:20
  • @CelticWarrior I am familiar with SWAP being a partition on your HDD, I check and have swap 12Gb actually. That which I do not understand is Linux running at 6Gb usage (atm), a few chrome tabs, QT Creator Studio, Plex, Atom and a few nautilus instances, all taking up 5.7Gb ram. It seems that Windows has much beter memory management...(Yes I just said Windows MM > Linux MM :p) – Cybex Oct 5 '16 at 12:24
  • With 8GB of RAM you could go without swap but it's better to have some, let's say ~2GB. I cannot and will not compare it to Windows and it's irrelevant for your question. In it you seem to imply you should be having more swap used which is nonsense. And the list you gave can easily take that much memory and more. FYI, any modern web browser will gulp as many as it can and what the tabs are matters way more than how many they are. – user589808 Oct 5 '16 at 12:32

If you'd run the top command, you'd see something in line with this:

KiB Mem:  32868436 total, 32695528 used,   172908 free,       20 buffers
KiB Swap:        0 total,        0 used,        0 free. 31194124 cached Mem

In this particular case, we have 32 gigs of RAM, of which just 172 MiB is shown as "free".
We do not have swap at all in our case.

Yet, to calculate the "real" free memory, add "cached Mem" to "free" and you would see that almost all of the memory is free.
The trick is that "cached Mem" is basically disk cache - Linux would use most of available free memory just for that to speed up disk operations. Do not worry - should a necessity for extra memory arise, Linux can instantly reduce the disk cache and use that for whatever purposes are needed. You only need to start worrying once both "free" and "cached Mem" are very small - that would mean you probably need a RAM upgrade to keep things running smoothly.

As to swap, I would agree with the previous replies that you don't want to use it in vain in cases where you have plenty of RAM. And 8 gigs are plenty for a desktop, if you are not using some heavy graphics processing software or such.

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.