View Single Post
HumanPenguin's Avatar
Posts: 270 | Thanked: 170 times | Joined on Jul 2007 @ Atlanta, GA + Oxford UK
#14
well there are a few ways to get free memory. the most useful for this widget would be

head -n 2 /proc/meminfo | tail -n 1

this will give you free mem in one line.

More informative is the command free that will give you more info on how it is allocated.

the command I gave is chopping one line out of the meminfo file. from an xterm type

cat /proc/meminfo

To see it all.

the field I have taken above is memfree. But I do not think that is very useful due to the way linux uses memory. Someone who knows more about the linux memory model nay be able to provide more useful info.
 

The Following 2 Users Say Thank You to HumanPenguin For This Useful Post: