Below is the output of free in Ubuntu:
$ free total used free shared buffers cached Mem: 8173180 8013092 160088 0 1076276 3091136 -/+ buffers/cache: 3845680 4327500 Swap: 11719380 312 11719068
Total physical memory is 8 gb. Total used memory is close to that, but the total memory used by buffer cache is half that, approximately 4 gb. Hardly any memory is being used as swap.
Now the buffer cache is derived because we have had read/writes to disk and then after first time, the applications are loaded in memory until no longer needed to speed up read/writes. So the total of read/writes for disk buffering is the 4 gb.
Ok, but what kind of processes are using the other 4 gigs of physical memory (excluding buffer cache)? How can I determine that?