Accessing process memory usage
April 21st, 2009
Did some googling and figured out it’s not too difficult to get your processes rough memory usage. Packged things up as a basic ruby extension and now from ruby you can access the process memory usage via:
RMem::Report.memory
It return’s the number of bytes reported as in use by the specific system… In the case of linux reading from the /proc file system and Darwin using the libproc.h.
Check it out here: http://github.com/taf2/rmem/tree/master

cool. windows support would be great (not that i use windows – just that i’ve heard some do
)
@ry
Yeah, I thought about it, it shouldn’t be too difficult, Microsoft does a good job documenting here: http://msdn.microsoft.com/en-us/library/ms682050(VS.85).aspx
@ry
Alright, windows support now included…