My laptop has started swapping like a cat: When I do nothing, it does nothing, but as soon as I do something it starts swapping.
$ free
total used free shared buff/cache available
Mem: 32691536 27932080 725360 2694016 4034096 1311600
Swap: 165950456 80476784 85473672
Based on this I would expect 27-4 GB = 23 GB is used for resident programs. But according to ps
only 7.5 GB are used by RSS:
$ ps aux | perl -ane '$s+=$F[5];END{print "$s\n"}'
7596328
What am I missing?
ps aux --sort -rss | head
will show the processes using the most memory. – Nasir Riley Feb 26 '23 at 20:42