Thursday Jan 21, 2010

newbar: a Post-Processing Visualization tool

newbar 1.0: for Solaris 9 and higher

Originally there was perfbar.
"perfbar" gives a near realtime view of CPU utilization states.
In perfbar red=kernel, green=user, yellow=wait on IO, blue=idle, and white is indeterminate.

It is common for an early indication of a performance issue to be obvious in perfbar.

I decided that it would be wonderful to have a perfbar for threads. So I borrowed the gui for perfbar and modified it to use procfs to access thread CPU utilization states and display them ala perfbar.

In thrbar :
white=indeterminate
green=user
red=kernel
yellow=latency
orange=wait for Lock
blue-green=wait for PageFault color
blue=SLEEP

Many times I am working with flat files of mpstat, prstat, or my own tool, tpry, data. With 256 CPUs, up to 100 instances of a process and sometimes thousands of threads, it has become much too time consuming to graph and view all of that data.

So I have invented newbar. newbar takes prstat -mcL , mpstat, or tpry output and displays it in perfbar or thrbar format.

I have 3 scripts to accomplish these tasks:
do_newbar
do_newbar_by_execname
and do_newbar_mp

do_newbar accepts an execname and number of rows for the display and post-processes the prstat.out and/or tpry.out file in the current working directory, displaying the threads for each pid with the given execname.

do_newbar_by_execname accepts an execname and processes all processes of that name in the tpry.out or prstat.out file simultanously at the process level(ie lwp 1). do_newbar_mp post processes mp.out in the CWD.

I have prebuilt the binaries. Sorry, I can not distribute the source. cp newbar.i386_32 or newbar.i386_32 or newbar.sparc_32 or newbar.sparc_64 to newbar and you are ready.

There are sample datasets included.

For do_newbar, copy tpry.out.sav to tpry.out and/or copy prstat.out_notimestamps or prstat.out_wtimestamps to prstat.out and run do_newbar java 4 .

For do_newbar_mp, just copy
mp.out_ntimestamps or
mp.out_wtimestamps to mp.out

Do not forget to gunzip the files.

For do_newbar_by_execname
cp tpry_for_by_execname.out to tpry.out
or cp prstat_for_by_execname.out to prstat.out and run do_newbar_by_execname foobar 4

Get newbar here

thrbar : perfbar for threads

thrbar 1.0, for Solaris 9 and higher

Originally there was "perfbar".

"perfbar" gives a near realtime view of CPU utilization states.
In perfbar red=kernel, green=user, yellow=wait on IO, blue=idle, and white is indeterminate.

It is common for an early indication of a performance issue to be obvious in perfbar.

I realized that it would be wonderful to have a perfbar for threads. So I borrowed the gui for perfbar and modified it to use procfs to access thread CPU utilization states and display them ala perfbar.

In thrbar
white=indeterminate
green=user
red=kernel
yellow=latency (wait for cpu)
orange=wait for Lock
blue-green=wait for PageFault
blue=SLEEP

I have prebuilt the binaries.
Sorry, I can not distribute the source.
cp thrbar.i386_32 or thrbar.i386_64 or thrbar.sparc_32 or thrbar_64 to thrbar and you are ready.

Get thrbar here

thrbar -help:

thrbar 1.0

maintained by Rick Weisner
based on the original perfbar by:
Joe Eykholt, George Cameron, Jeff Bonwick, Bob Larson

Usage: thrbar [X-options] [tool-options]
supported X-options:
-display or -disp
-geometry or -geo
-background or -bg
-foreground or -fg
-font or -fn
-title or -t
-iconic or -icon
-foreground or -fg
-font or -fn
-title or -t
-iconic or -icon
-decoration or -deco

supported tool-options:
-h, -H, -? or -help: this help
-v or -V: verbose
-r or -rows: number of rows to display, default 1
-bw or -barwidth: width of bars, default 12
-bh or -barheight: height of bar, default 180
-i or -idle: indeterminate color default white
-u or -user: user color, default green
-s or -system: system color, default red
-w or -wait: Latency color, default yellow
-l or -lock: Wait for Lock color, default orange
-f or -fault: Wait for PageFault color, default blue/green
-sl or -sleep: SLEEP color, default blue
-int or -interval: interval for display updates (in ms), default 1000
-si or -statsint: interval for stats updates (in display intervals), default 1
-pid pid number to monitor "

About

user12610965

Search

Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today