Thanks Dan :)
 
but the module seems to be intended not for Solaris 10
[EMAIL PROTECTED]:/u/nikhil/temp/Solaris-0.05> perl Makefile.PL PREFIX="${HOME}/mypm/"
Solaris:: is only supported on Solaris 2.5.1, 2.6 & 2.7
 
Thanks,
Nikhil

 
On 10/27/05, Dan Price <[EMAIL PROTECTED]> wrote:
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
[email protected]

Reply via email to