This is a lightweight library that wraps access to the data in /proc/meminfo found in many linux variants, which contains live memory usage information about a machine.
Install the gem:
gem install mem_info
Require the library like you would expect:
Then create a new MemInfo object:
m = MemInfo.new m.memtotal => 70000 m.memfree => 54300 m.memused => 15700 m.free_buffers => 75000
Take a look in lib/mem_info.rb for all fields that are available.
Copyright © 2010 Joel Watson. See LICENSE for details.