Question

I am looking to find the SunOS system details using Kstat. I have found Solaris::Kstat module in CPAN but this only supports Solaris 2.5.1, 2.6 & 2.7. The Sun developer's site mentions a Sun::Solaris::Kstat which I have not found in CPAN. Can anyone please help me with the Perl scripting to find details from kstat on Solaris 5.10.

Was it helpful?

Solution

According to Brendan Gregg who actually develops Perl tools to work with Solaris systems:

The KStat perl library is shipped with Solaris.

However, in one of his modules he includes the following note:

# - If you have upgraded /usr/bin/perl, this program may be unable to 
#   find the Sun::Solaris::Kstat library (which is under /usr/perl5).
#   Before the "use strict;" line, you may need to add,
#   use lib "/usr/perl5/5.6.1/lib";
#   to point to your location of Sun/Solaris/Kstat.pm.

If that doesn't work, you may want to run a find command for Kstat.pm, to be certain of whether or not this file exists anywhere on your system.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top