In Linux, for a 8GB RAM server, when could we say virtual memory is actually used more? I.e., what is the number of page faults which says system is using more virtual memory?

  • Memory usage (excluding cache/buffers) will of course be exactly the same, as will virtual memory usage. Are you perhaps referring to swap? – Daniel B Dec 24 '16 at 22:50

Of course yes, Virtual Memory (known as Swap in Linux) will be used less when there is enough memory.

There is a kernel parameter called swappiness that controls how much swap is likely to be used. Tune it to your needs. To see current value (all commands need root):

cat /proc/sys/vm/swappiness

and to set the value

sysctl vm.swappiness=10

and to persist it, open /etc/sysctl.conf and add (or change)


More information here.

Consider value as percent, and less value means using less swap.

On my laptop with 16GB RAM, using 10 I'm just fine.

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.