Project

mem_info

0.01
Repository is archived
No commit activity in last 3 years
No release in over 3 years
Ruby wrapper for /proc/meminfo data
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 1.2.9
 Project Readme

mem_info

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.

Getting Started

Install the gem:

gem install mem_info

Require the library like you would expect:

require 'mem_info'

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

Copyright (c) 2012 Joel Watson. See LICENSE for details.