[mrtg] Re: Solaris SNMP
Kyle Maxwell
kyle.maxwell at telops.gte.com
Wed Sep 1 15:26:16 MEST 1999
To track a specific process, you should be able to do something like
ps -A | grep <appname> | awk 'print $1'
to get the process ID (that awk portion may be a little off). You can put in other options to ps to get other data you want about that process.
For general CPU system/idle time, I have a tiny script that essentially does
vmstat 1 2 | sed '$!D' | awk -f statget.awk
where statget.awk prints out the fields I'm interested in. There's probably more "elegant" ways to get this done, but as a quick and dirty hack, it did well.
Obviously, all this totally goes around SNMP, but it's quick, eh?
--
Kyle Maxwell
Systems Engr (Firewall Security)
GTE Enterprise Information Protection Systems
---------- Original Text ----------
From: "Neil Calvert" <ncalvert at cabletron.com>, on 8/31/99 4:16 PM:
Hi all.
I'm looking into the possibility of using MRTG against a Solaris SNMP agent (the basic Solstice agent) and I was wondering if people are doing this already, and if so, what applications they've found it useful for? Currently I can see mrtg being able to graph SNMP stats, interface traffic, and so on, but I'd like to get more OS specific information like total CPU time vs. Idle time. The Sun mib lets you see cpu time as an instanced mib where every process on the system is listed. The problem with this of course is that it will be dynamically changing as processes are starting and stopping. Is there any way to 'alias' an executable name to a process, so you ask it to graph say 'application A CPU time' and it goes off and finds out what 'application A's processID is to get the mib value?
I'm guessing this is probably a script hack but if there are any sun mibs out there that may help I'd be grateful to hear of them.
Neil
--
* To unsubscribe from the mrtg mailing list, send a message with the
subject: unsubscribe to mrtg-request at list.ee.ethz.ch
* The mailing list archive is at http://www.ee.ethz.ch/~slist/mrtg
More information about the mrtg
mailing list