I have a laptop with 4 GB RAM and i3 processor. It runs very fast when I use windows, but it keeps slowing down on my Ubuntu when I use it continuously. I noticed that 500mb+ swap is getting used even if only 20% of RAM is only used, and I have a doubt that this is the reason for the slowness. I have already set the swappiness value to 10. Then how else can I change it? I spend most of my time in Ubuntu so this is very important for me.


If you have enough memory, for e.g. your 4 gb, swappines will have no impact to system performance at all, because in that configuration most likely your system wont swap at all (or just to reserve mem-space). if you have few memory swappines may have impact to system performance. But its kind of a religious question with endless debates which value should be recommended. Alan Cox recommends a value near by 100. Other Kernel-Hackers recommends very lower values (the ubuntu default of 10 is often recommended). But from my experience it does not make a feelable difference in performance at all. So you could leave it by ubuntu default value (60) or choose the ubuntu recommended 10 for desktop systems.


Use this command to confirm that your change is being used (i.e., that it was saved permanently):

cat /proc/sys/vm/swappiness

Also, maybe the swap FAQ will help.

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.