Archive for the 'linux command line' Category

how to show memory usage

$ free

             total       used       free     shared    buffers     cached
Mem:        254900     251276       3624          0       1904      69848
-/+ buffers/cache:     179524      75376
Swap:       746980      55800     691180

how to show disk space usage

$ df -h


Filesystem            Size  Used Avail Use% Mounted on
/dev/sda1              27G   12G   15G  45% /
...

note: the -h parameter means “human-readable.”