Memory In Linux


To check memory usage in Linux do:

cat /proc/meminfo

You'll get a long listing of all memory usage.

Use free to show memory usage in megabytes:

free -m

You can use -k for kilobytes or -G for gigabytes.

There is vmstat too:

vmstat 2 5

vmstat displays output every 2 seconds 5 times.