I'd like to write my own server monitoring app. Ideally it could show stats like load, uptime, cpu activity, most active processes, memory usage by process, etc. What's the best way to grab that information from the server? I was initially thinking of running ssh -e commands, but wanted to see if there was a more efficient way than polling the server.
Alternatively, would it be best to tie into data that's being aggregated by Munin or a similar monitoring tool?
To be more clear, I'm mainly interested in the best way to get the sorts of data mentioned above from a server so I can render it in an Android app I'm interested in building. Writing the actual probes on the server itself isn't really in the domain of work I want to do, which is why I'm hoping Nagios or something similar might already provide the data im looking for. I would just need to pull that data and render it in my own tool.