September 18, 2014

Basic performance and diagnostic tools on Solaris

Much has been written about tools to inspect Linux systems, and much has been written about Solaris’s Big Important Tools such as DTrace. But I don’t recall seeing much in the MySQL blogs about basic tools to find one’s way around a Solaris system and discover the system, get fundamental performance, configuration, and status information, and so on. Here’s a quick list of some key tools.

  • Many of the tools you’re used to from Linux will work, although sometimes they output different information. An example is vmstat. Many tools such as uptime will work as you’re used to. And of course, Solaris is POSIX compliant, so if a core UNIX utility doesn’t do what you want, the problem is you ;-)
  • One example of a tool that is often installed on Solaris but should not be preferred is top. Instead, you should use the native Solaris tool, prstat, which is more accurate.
  • To display information about processors, use psrinfo.
  • To print system configuration (such as sysctl gives you), use prtconf and/or sysdef.
  • To print system diagnostic information, use prtdiag.
  • To describe the hardware’s instruction set architecture, use isainfo and isalist.
  • To discover some low-level hardware details, use smbios.
About Baron Schwartz

Baron is the lead author of High Performance MySQL.
He is a former Percona employee.

Comments

  1. j2534 diagnostic says:

    dfdsfgdsdfs

  2. diagnostic tool says:

    hello,good post!

  3. Some commands can’t be run in a Solaris non-global Zone. E.g., smbios and prtdiag. Also prtconf says “devinfo facility not available” but I’m not sure if that’s due to Solaris Zones.

    I used “psrinfo -vp” to get full information about processors. With other commands you get rather generic information about the processors, for instance isainfo only told me the processors supported “am64 and pentium_pro+mmx” instructions, which is less than I wanted to know. psrinfo -vp told me exactly which model of Xeon processors are installed, clock speed, and number of cores per processor.

    I’m still looking for a way to map disk devices reported in iostat to the mounted filesystems. Is this also complicated by the virtualization of devices in Zones?

  4. Another tip for Solaris Zones: Both `prtconf’ and `top’ can report an inaccurate number for the amount of physical RAM. The Solaris Container (sort of analogous to a Host operating system in VM lingo) can cap the amount of physical RAM used by a zone. Run `zonecfg -z info’ on the Container to get the actual RAM allocated to a given Zone.

  5. In the above comment I tried to use angle-brackets but they got lost. The command I was trying to describe is `zonecfg -z zonename info’, where zonename is the name of a given Solaris Zone instance.

  6. The command ‘zonename’ will show if you are in the global zone (e.g. not a zone) or if you’re inside a zone. A bunch of the commands won’t work inside a zone.

  7. Hi,

    Take a look at SDR, designed special to record long trends from your Solaris/Linux boxes.
    http://www.systemdatarecorder.org/download/index.html Im planning to add support for FreeBSD.

    You could use sar and gather all data what you need, but SDR does a bit better by letting you
    have different recorders for different jobs without stopping anyone to enhance, modify them
    in matter of minutes.

    Very nice post about VoltDB/USL.

Speak Your Mind

*