Main > Programming > Libraries >

Solaris::Kstat 0.05a

Solaris::Kstat 0.05a

Sponsored Links

Solaris::Kstat 0.05a Ranking & Summary

RankingClick at the star to rank
Ranking Level
User Review: 0 (0 times)
File size: 0.024 MB
Platform: Any Platform
License: Perl Artistic License
Price:
Downloads: 874
Date added: 2007-06-13
Publisher: Alan Burlison

Solaris::Kstat 0.05a description

Solaris::Kstat is a Perl module to access Solaris Kstats from Perl.

SYNOPSIS

use Solaris::Kstat;
my $kstat = Solaris::Kstat->new();
my ($usr1, $sys1, $wio1, $idle1) =
@{$kstat->{cpu_stat}{0}{cpu_stat0}}{qw(user kernel wait idle)};
print("usr sys wio idlen");
while (1)
{
sleep 5;
if ($kstat->update()) { print("Configuration changedn"); }
my ($usr2, $sys2, $wio2, $idle2) =
@{$kstat->{cpu_stat}{0}{cpu_stat0}}{qw(user kernel wait idle)};
printf(" %.2d %.2d %.2d %.2dn",
($usr2 - $usr1) / 5, ($sys2 - $sys1) / 5,
($wio2 - $wio1) / 5, ($idle2 - $idle1) / 5);
$usr1 = $usr2; $sys1 = $sys2; $wio1 = $wio2; $idle1 = $idle2;
}

This module provides a tied hash interface to the Solaris kstats library. The kstats library allows you to get access to all the stats used by sar, iostat, vmstat etc, plus a lot of others that arent accessible through the usual utilities.
Solaris categorises statistics using a 3-part key - module, instance and name. For example, the root disk stats can be found under sd.0.sd0, and the cpu statistics can be found under cpu_stat.0.cpu_stat0, as in the above example. The method Solaris::Kstats-new()> creates a new 3-layer tree of perl hashes with exactly the same structure - i.e. the stats for disk 0 can be accessed as $ks-{sd}{0}{sd0}>. The bottom (4th) layer is a tied hash used to hold the individual statistics values for a particular system resource.

Creating a Solaris::Kstat object doesnt actually read all the possible statistics in, as this would be horribly slow and inefficient. Instead it creates a 3-layer structure as described above, and only reads in the individual statistics as you reference them. For example, accessing $ks-{sd}{0}{sd0}{reads} will read in all the statistics for sd0, including writes, bytes read/written, service times etc. Once you have accessed a bottom level statitics value, calling $ks->update() will automatically update all the individual values of any statistics that you have accessed.

Note that there are two values per bottom-level hash that can be read without causing the full set of statistics to be read from the kernel. These are "class" which is the kstat class of the statistics and "crtime" which is the time that the kstat was created. See kstat(3K) for full details of these fields.

Solaris::Kstat 0.05a Screenshot

Advertisements

Solaris::Kstat 0.05a Keywords

Bookmark Solaris::Kstat 0.05a

Hyperlink code:
Link for forum:

Solaris::Kstat 0.05a Copyright

WareSeeker periodically updates pricing and software information of Solaris::Kstat 0.05a full version from the publisher, so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of Solaris::Kstat 0.05a Edition. Download links are directly from our publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed

Allok Video Splitter 2.2.0 Review:

Name (Required)
Email(Required)
Captcha
Featured Software

Want to place your software product here?
Please contact us for consideration.

Contact WareSeeker.com
Related Software
Solaris::MapDev Perl module contains a map between instance numbers and device names. Free Download
dump_kstat is a Perl module created to dump the kstat structure. Free Download
Solaris::Disk::SVM::Graph is a Perl module for graph your Solaris Volume Manager configurations. Free Download
Etk::Constants is a Perl module with costants to use with Etk. Free Download
Zonestats create an RRD database with the values of CPU and memory (RSS) usage per Solaris 10 zone. Free Download
RPM::Constants is a Perl module with groups of RPM-defined symbols. Free Download
Webalizer::Hist is a Perl module to parse the webalizer.hist-file. Free Download
Convert::Braille is a Perl module that can convert Between Braille Encodings. Free Download