Also an additional command line argument to specify the number of
iterations of rstat (sort of like vmstat) would be helpful. The
following patch adds this option and fixes the intervall bug.
===================================================================
RCS file: /sources/cvsrepos/scotty_tkined/scotty/examples/rstat,v
retrieving revision 1.1.1.3
diff -r1.1.1.3 rstat
58c58
< puts stderr "usage: rstat hostname interval"
--- > puts stderr "usage: rstat hostname interval \[iterations\]" 62c62 < if {[llength $argv] != 2} { usage } else {--- > if { !([llength $argv] == 2 || [llength $argv] == 3)} { usage } else { 65,66c65,72 < set interval [expr {$intervall<1 ? 1 : $interval}] < while {1} {--- > set interval [expr {$interval <1 ? 1 : $interval}] > if {[llength $argv] == 3} { > set iterations [lindex $argv 2] > } else { > set iterations -1 > } > > while { $iterations != 0 } { 74a81,82 > > if { $iterations > 0 } { incr iterations -1 }
Also does anybody have a simple snmp script along the lines of the rstat script that will grab an oid or name from a remote host?
-- John John Rouillard Senior Systems Administrator IDD Information Services rouilj@dstar.iddis.com Waltham, MA (617) 890-1576 x103 Senior Systems Consultant (SERL Project) University of Massachusetts at Boston rouilj@cs.umb.edu (preferred) Boston, MA, (617) 287-6480 =============================================================================== My employers don't acknowledge my existence much less my opinions.