On Wed 26 Oct 2005 at 04:43PM, Nikhil wrote: > Hello friends > > > Can any one please tell me how can I acess libkstat with perl. I mean > using API
Does this help? -dp - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # # Example derived from the SUN::SOLARIS::KSTAT man page: # man -M /usr/perl5/man -s3 Sun::Solaris::Kstat # use Sun::Solaris::Kstat; my $ks = Sun::Solaris::Kstat->new(); $ks->update(); print "Boot Time as a time_t: "; print $ks->{'unix'}{0}{'system_misc'}{'boot_time'} . "\n"; print "Boot Time As a time: "; print localtime($ks->{'unix'}{0}{'system_misc'}{'boot_time'}) . "\n"; while (1) { print "number of processes: "; print $ks->{'unix'}{0}{'system_misc'}{'nproc'} . "\n"; sleep 1; $ks->update(); } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -- Daniel Price - Solaris Kernel Engineering - [EMAIL PROTECTED] - blogs.sun.com/dp _______________________________________________ opensolaris-discuss mailing list opensolaris-discuss@opensolaris.org