[Orca-checkins] r294 - in trunk/orca/data_gatherers: aix hp
Blair Zajac
blair at orcaware.com
Sat Apr 3 16:07:46 PST 2004
Author: blair
Date: Sat Apr 3 16:07:15 2004
New Revision: 294
Added:
trunk/orca/data_gatherers/aix/orca-aixtsm-stat.pl (contents, props changed)
trunk/orca/data_gatherers/aix/orcallatorAIX.cfg (contents, props changed)
trunk/orca/data_gatherers/aix/orcallatorTSM.cfg (contents, props changed)
trunk/orca/data_gatherers/hp/
trunk/orca/data_gatherers/hp/hporcallator.cfg (contents, props changed)
trunk/orca/data_gatherers/hp/orca-hp-stat.pl (contents, props changed)
Log:
Add an hp data_gatherers directory, a new HP data gatherer and an
additional AIX data gatherer.
* data_gatherers/aix/orca-aixtsm-stat.pl,
* data_gatherers/aix/orcallatorAIX.cfg,
* data_gatherers/aix/orcallatorTSM.cfg:
Initial import of another AIX data measurement tool and Orca
configuration files. Submitted by Rajesh Verma
<rajesh.verma at palmettohealth.org>.
* data_gatherers/hp:
New directory.
* data_gatherers/hp/orca-hp-stat.pl,
* data_gatherers/hp/hporcallator.cfg:
Initial import of an HP data measurement tool and Orca configuration
file. Submitted by Rajesh Verma <rajesh.verma at palmettohealth.org>.
Added: trunk/orca/data_gatherers/aix/orca-aixtsm-stat.pl
==============================================================================
--- (empty file)
+++ trunk/orca/data_gatherers/aix/orca-aixtsm-stat.pl Sat Apr 3 16:07:15 2004
@@ -0,0 +1,630 @@
+#!/usr/bin/perl
+#
+# Version 1.7
+
+# Description:
+# Collect general perfromance statistics formatted for
+# interpretaion by Orca.
+
+# Usage:
+# The following variables may be set:
+#
+# OUT_ROOT root directory for datafiles (eg /opt/log/performance)
+# INTERVAL the number of seconds between checks (eg 300 = 5 min)
+# DURATION numer of hours to run (eg 1 = 1 hr)
+#
+# This script runs various standard system utilities to collect
+# system performance statistics and writes them out to datafile named
+# HOSTNAME/stats.YYYY-MM-DD-HHmm under the OUT_ROOT directory.
+#
+# It runs for the the numbers specified by DURATION collecting data
+# every INTERVAL number of seconds. After DURATION, the script
+# closes and compresses it's datafile via /usr/bin/compress and then
+# exits. If DURATION=24 and INTERVAL=300 (recommended) then the
+# following cron entry would collect continuos stats for a system:
+#
+# 0 0 * * * /<PATH_TO_SCRIPT>/orca-aix-stat.pl
+#
+# 2003-09-10 - RV - Modified for AIX 4.3/5.x.. by Rajesh Verma
+# (rajeshverma at aixdude.com)
+# v1.7 - RV - ignores /proc now
+# 2001-04-16 - JDK - Genesis... by Jason D. Kelleher
+# 2001-05-02 - JDK - Updates to make data aggregation easier.
+# Added #open connections, pagestotl.
+# 2001-07-06 - JDK - added command-line args & data checks
+# 2001-07-09 - JDK - added signal handler, column checks, & umask
+# 2001-07-10 - JDK - now autodetects interfaces via netstat -i
+# v1.5
+#
+# $HeadURL$
+# $LastChangedDate$
+# $LastChangedBy$
+# $LastChangedRevision$
+
+# Note: Execution speed is more important than cleanliness here.
+
+# Explicitly set PATH to prevent odd problems if run manually.
+$ENV{PATH} = '/usr/bin:/etc:/usr/sbin:/usr/ucb:/sbin';
+
+$Usage_Message = '
+Usage: orca-aix-stat.pl [-r out_root] [-i interval] [-d duration] [-h]
+
+-r out_root set root output directory, default: /opt/log/performance
+-i interval number of seconds between checks, default: 300
+-d duration number of hours to run, default: 24
+-h this message
+
+';
+############################
+# These are the packages you need to install
+# 1. perl
+# 2. openssh - if using ssh to the collector server
+# 3. openssl
+# 4. zlib
+# 5. rsync - To copy file to the collector server
+# 6. gzip - to zip the files
+# 7. rpm.rte - to install rpm tools
+#
+# This the site you can file everything
+# http://www-1.ibm.com/servers/aix/products/aixos/linux/download.html
+# http://www.bullfreeware.com
+#
+#
+# Good Luck, Rajesh Verma (rajeshverma at yahoo.com)
+##############################
+
+# Parse the command line arguments
+while ( $#ARGV >= 0 ) {
+
+ if ( $ARGV[0] eq "-r" ) {
+ shift @ARGV;
+ $OUT_ROOT = shift @ARGV;
+ }
+ elsif ( $ARGV[0] eq "-i" ) {
+ shift @ARGV;
+ $INTERVAL = shift @ARGV;
+ }
+ elsif ( $ARGV[0] eq "-d" ) {
+ shift @ARGV;
+ $DURATION = shift @ARGV;
+ }
+ elsif ( $ARGV[0] eq "-h" ) {
+ print $Usage_Message;
+ exit 0;
+ }
+ elsif ( $ARGV[0] =~ /^-/ ) {
+ die "Invalid flag: $ARGV[0]\n$Usage_Message";
+ }
+ else {
+ die "Invalid argument: $ARGV[0]\n$Usage_Message";
+ }
+}
+
+## BEGIN set defaults
+
+$OUT_ROOT ||= '/home/orca/orcallator'; # root directory for datafiles
+$INTERVAL ||= 300; # seconds between checks
+$DURATION ||= 24; # number of hours to run
+
+## END set defaults
+
+## Derived variables.
+$iterations = $DURATION * 60 * 60 / $INTERVAL; # Number of checks.
+chomp( $HOST = `uname -n` );
+$out_dir = "${OUT_ROOT}/${HOST}";
+( $sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst ) =
+ localtime(time);
+$stat_file =
+ sprintf( "%s/percol-%.2d-%.2d-%.2d-%1d%.2d", $out_dir, $year + 1900, $mon + 1,
+ $mday, $hour, $min );
+
+# Base all timestamps on start time.
+$start_time = time();
+$timestamp = 0;
+
+## Autodetect network interfaces
+#open IN, "ifconfig -a|";
+open IN, "netstat -ni|";
+while (<IN>) {
+
+ # if ( /^(\S+):/ ) {
+ if (/^(\w+).*link/) {
+ push @net_interfaces, $1;
+ }
+}
+close IN;
+
+# Grab some base system info prior to collecting stats.
+open IN, "lsattr -El sys0 -a realmem |";
+while (<IN>) {
+ if (/^realmem (\d+) /) {
+ $pagestotl = $1 * 1024 / 4096; # Grab realmem in KB and convert to pages.
+ $mem_totl = $1 * 1024; # Grab realmem in KB and convert to Bytes.
+
+ # this gets used down in the vmstat section
+ }
+}
+close IN;
+
+## Make sure we can write output.
+umask 0022; # make sure the file can be harvested
+unless ( -d $out_dir ) {
+ system( "mkdir", "-p", "$out_dir" );
+}
+open OUT, ">$stat_file" or die "ERROR: Could not open $stat_file: $!";
+my $oldfh = select OUT;
+$| = 1;
+select $oldfh;
+
+# Set signal handlers to close and compress the output
+# file just in case.
+$SIG{HUP} = \&exit_nicely;
+$SIG{INT} = \&exit_nicely;
+$SIG{QUIT} = \&exit_nicely;
+$SIG{TERM} = \&exit_nicely;
+
+# Set gloabals used for printing (or not) headers.
+$need_header = 1;
+$prev_header_cnt = 0;
+$prev_info_cnt = 0;
+
+while ( $iterations-- > 0 ) {
+
+ $timestamp = $timestamp ? time() : $start_time;
+ ( $sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst ) =
+ localtime(time);
+ $locltime = sprintf( "%.2d:%.2d:%.2d", $hour, $min, $sec );
+
+ ## Get runq data
+ ## Get runq data
+ $uptime = 0;
+ open IN, "uptime |";
+ while (<IN>) {
+ if (/load average:\s+(\S+),\s+(\S+),\s+(\S+)/) {
+ $load_info = join "\t", $1, $2, $3;
+ }
+ @upt = split(/ +/,);
+ $uptd = $upt[3];
+ $nusr = $upt[6];
+ $up_day = $uptd * 24 * 60 * 60;
+ if (/days,\s+(\S+):(\S+), /) {
+ $up_hrs = $1 * 60 * 60;
+ $up_min = $2 * 60;
+ }
+ $uptime = $up_day + $up_hrs + $up_min;
+ }
+ close IN;
+ $load_header = "1runq\t5runq\t15runq";
+ $up_header = "uptime\tnusr";
+ $up_info = "$uptime\t$nusr";
+
+ if ( scalar( split ' ', $load_header ) != scalar( split ' ', $load_info ) )
+ {
+ $load_header = '';
+ $load_info = '';
+ $need_header = 1;
+ print STDERR "WARNING: load header does not match load info.\n";
+ }
+ if ( scalar( split ' ', $up_header ) != scalar( split ' ', $up_info ) )
+ {
+ $up_header = '';
+ $up_info = '';
+ $need_header = 1;
+ print STDERR "WARNING: UP header does not match load info.\n";
+ }
+
+
+ ## Get number of system processes
+ $num_proc = -1; # Don't count the header.
+ open IN, "ps -ek |";
+ while (<IN>) {
+ $num_proc++;
+ }
+ close IN;
+ $proc_info = $num_proc;
+ $proc_header = '#proc';
+
+ if ( scalar( split ' ', $proc_header ) != scalar( split ' ', $proc_info ) )
+ {
+ $proc_header = '';
+ $proc_info = '';
+ $need_header = 1;
+ print STDERR "WARNING: #proc header does not match #proc info.\n";
+ }
+
+ ## Get pstat data for pages
+ $sw_used = 0;
+ $sw_free = 0;
+ open IN, "pstat -s |tail -3 |";
+ while (<IN>) {
+ @swp = split(/ +/,);
+ if (/\d/) {
+ $sw_used = $swp[1];
+ $sw_free = $swp[2];
+ $swap_used = $sw_used * 4096;
+ $swap_free = $sw_free * 4096;
+ }
+ }
+ close IN;
+ $swap_info = "$swap_used\t$swap_free";
+ $swap_header = "\tswap_used\tswap_free";
+
+ if ( scalar( split ' ', $swap_header ) !=
+ scalar( split ' ', $swap_info ) )
+ {
+ print STDERR "WARNING: pstat header does not match pstat info.\n";
+ $swap_header = '';
+ $swap_info = '';
+ $need_header = 1;
+ }
+
+
+
+ ## Get vmstat data
+ open IN, "vmstat 1 2|";
+ while (<IN>) {
+ chomp;
+ if (/^[\s\d]+$/) {
+
+ # overwrite first line on 2nd pass
+ (
+ $vmstat_r, $vmstat_b, $vmstat_avm, $vmstat_fre,
+ $vmstat_re, $vmstat_pi, $vmstat_po, $vmstat_fr,
+ $vmstat_sr, $vmstat_cy, $vmstat_inf, $vmstat_syf,
+ $vmstat_csf, $vmstat_us, $vmstat_sy, $vmstat_id,
+ $vmstat_wa )
+ = split;
+ $vmstat_info = join "\t", $vmstat_r, $vmstat_b, $vmstat_avm,
+ $vmstat_fre, $pagestotl, $vmstat_pi, $vmstat_po, $vmstat_fr,
+ $vmstat_sr, $vmstat_us, $vmstat_sy, $vmstat_wa, $vmstat_id;
+ }
+ }
+ close IN;
+ $vmstat_header =
+"runque\twaiting\tpagesactive\tpagesfree\tpagestotl\tPagesI/s\tPagesO/s\tPagesF/s\tscanrate\tusr%\tsys%\twio%\tidle%";
+
+ if ( scalar( split ' ', $vmstat_header ) !=
+ scalar( split ' ', $vmstat_info ) )
+ {
+ print STDERR "WARNING: vmstat header does not match vmstat info.\n";
+ $vmstat_header = '';
+ $vmstat_info = '';
+ $need_header = 1;
+ }
+
+ ## Get filesystem data
+ $fs_header = '';
+ $fs_info = '';
+ open IN, "df -k -v |";
+ while (<IN>) {
+ chomp;
+
+ if (m%^/dev%) {
+ ( $mnt_dev, $blocks, $used, $free, $pct_used, $iused, $ifree,
+ $ipct_used, $mnt ) = split;
+
+ # Recalculate percents because df rounds.
+ $fs_info .= "\t"
+ . sprintf( "%s\t%s\t%s\t%.5f\t%d\t%s\t%s\t%.5f", $blocks, $used,
+ $free, ( $used / $blocks ) * 100, ( $iused + $ifree ), $iused,
+ $ifree, ( $iused / ( $iused + $ifree ) ) * 100 );
+ $fs_header .= "\t" . join "\t", "mntC_$mnt", "mntU_$mnt",
+ "mntA_$mnt", "mntP_$mnt", "mntc_$mnt", "mntu_$mnt", "mnta_$mnt",
+ "mntp_$mnt";
+ }
+ }
+ close IN;
+
+ if ( scalar( split ' ', $fs_header ) != scalar( split ' ', $fs_info ) ) {
+ print STDERR
+ "WARNING: filesystem header does not match filesystem info.\n";
+ $fs_header = '';
+ $fs_info = '';
+ $need_header = 1;
+ }
+
+ ## Get iostat data
+ $disk_t = 0;
+ $disk_rK = 0;
+ $disk_wK = 0;
+ undef %disks;
+ open IN, "iostat -d 1 2|";
+
+ while (<IN>) {
+ if (/^(\S+)\s+\S+\s+\S+\s+(\S+)\s+(\d+)\s+(\d+)/) {
+ my $disk = $1;
+ my $tps = $2;
+ my $rK = $3;
+ my $wK = $4;
+ if ( not $disks{$disk} ) {
+ $disks{$disk}++; # Get rK & wK from first pass.
+ $disk_rK += $rK;
+ $disk_wK += $wK;
+ }
+ else {
+ $disk_t += $tps; # Get trans per sec from second pass.
+ }
+ }
+ }
+ close IN;
+ $iostat_header = "disk_t/s\tdisk_rK/s\tdisk_wK/s";
+ $iostat_info = "${disk_t}\t${disk_rK}\t${disk_wK}";
+
+ if ( scalar( split ' ', $iostat_header ) !=
+ scalar( split ' ', $iostat_info ) )
+ {
+ print STDERR "WARNING: iostat header does not match iostat info.\n";
+ $iostat_header = '';
+ $iostat_info = '';
+ $need_header = 1;
+ }
+
+ ## Get packet data
+ $packet_header = '';
+ $packet_info = '';
+
+ #foreach $interface ( split(/\s+/, $NET_INTERFACES) ) {
+ foreach $interface (@net_interfaces) {
+ $packet_header .=
+"\t${interface}Ipkt/s\t${interface}IErr/s\t${interface}Opkt/s\t${interface}OErr/s\t${interface}Coll/s\t";
+ open IN, "netstat -n -I $interface 1|";
+
+ while (<IN>) {
+ if (/^\s*(\d+)\s+(\d+)\s+(\d+)\s+(\d+)\s+(\d+)\s+/) {
+ $packet_info .= "\t" . join "\t", $1, $2, $3, $4, $5;
+ last;
+ }
+ }
+ close IN;
+ }
+
+ if ( scalar( split ' ', $packet_header ) !=
+ scalar( split ' ', $packet_info ) )
+ {
+ print STDERR "WARNING: packet header does not match packet info.\n";
+ $packet_header = '';
+ $packet_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TCP Connection data
+ $tcp_estb = 0;
+ open IN, "netstat -an |";
+ while (<IN>) {
+ if (/^tcp.+ESTABLISHED$/) {
+ $tcp_estb++;
+ }
+ }
+ close IN;
+ $tcp_info = $tcp_estb;
+ $tcp_header = 'tcp_estb';
+
+ if ( scalar( split ' ', $tcp_estb_header ) !=
+ scalar( split ' ', $tcp_estb_info ) )
+ {
+ print STDERR "WARNING: tcp_estb header does not match tcp_estb info.\n";
+ $tcp_estb_header = '';
+ $tcp_estb_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TSM Database space usage
+ $tsmdb = 0;
+ open IN, "dsmadmc -id=view -password=view 'query db' |tail -r -n 5 |";
+ while (<IN>) {
+ @fld = split(/ +/,);
+ if (/\d/) {
+ $tsmdb = $fld[8];
+ }
+ }
+ close IN;
+ $tsm_info = $tsmdb;
+ $tsm_header = "tsmdb\t";
+
+ if ( scalar( split ' ', $tsm_header ) !=
+ scalar( split ' ', $tsm_info ) )
+ {
+ print STDERR "WARNING: tsmdb header does not match tsmdb info.\n";
+ $tsm_header = '';
+ $tsm_info = '';
+ $need_header = 1;
+ }
+
+ ## Get Memory Usage breakup using SVMON
+ $mem_work = 0;
+ $mem_pres = 0;
+ $mem_clnt = 0;
+ open IN, "svmon -G |tail -2 |";
+ while (<IN>) {
+ @memp = split(/ +/,);
+ if (/use\s+(\d+) /) {
+ $m_work = $memp[2];
+ $m_pres = $memp[3];
+ $m_clnt = $memp[4];
+ $mem_work = $m_work * 4096;
+ $mem_pres = $m_pres * 4096;
+ $mem_clnt = $m_clnt * 4096;
+ }
+ }
+ close IN;
+ $mem_info = "$mem_work\t$mem_pres\t$mem_clnt\t$mem_totl";
+ $mem_header = "mem_work\tmem_pres\tmem_clnt\tmem_totl";
+
+ if ( scalar( split ' ', $mem_header ) !=
+ scalar( split ' ', $mem_info ) )
+ {
+ print STDERR "WARNING: memory header does not match memory info.\n";
+ $mem_header = '';
+ $mem_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TSM Tape Drive usage
+ $rmt = 0;
+ $rmt5 = 5;
+ open IN, "dsmadmc -id=view -password=view 'query mount' |grep matches |";
+ while (<IN>) {
+ @fld = split(/ +/,);
+ if (/\d/) {
+ $rmt = $fld[1];
+ }
+ }
+ close IN;
+ $tsm_rmt_header = "rmt5\trmt\t";
+ $tsm_rmt_info = "$rmt5\t$rmt";
+
+ if ( scalar( split ' ', $tsm_rmt_header ) !=
+ scalar( split ' ', $tsm_rmt_info ) )
+ {
+ print STDERR "WARNING: TSM RMT header does not match TSM RMT info.\n";
+ $tsm_rmt_header = '';
+ $tsm_rmt_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TSM Recovery Log space usage
+ $tsmdb = 0;
+ open IN, "dsmadmc -id=view -password=view 'query log' |tail -r -n 4 |";
+ while (<IN>) {
+ @fld = split(/ +/,);
+ if (/\d/) {
+ $tsmlog = $fld[8];
+ }
+ }
+ close IN;
+ $tsm_log_info = $tsmlog;
+ $tsm_log_header = 'tsmlog';
+
+ if ( scalar( split ' ', $tsm_log_header ) !=
+ scalar( split ' ', $tsm_log_info ) )
+ {
+ print STDERR "WARNING: TSM Log header does not match TSM Log info.\n";
+ $tsm_log_header = '';
+ $tsm_log_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TSM Tape usage
+ $tsmpvt = 0;
+ open IN, "dsmadmc -id=view -password=view 'query libvol' | grep 'Private' | wc -l |";
+ while (<IN>) {
+ chomp;
+ @fld = split(/ +/,);
+ if (/\d/) {
+ $tsmpvt = $fld[1];
+ }
+ }
+ close IN;
+
+ $tsmscr = 0;
+ open IN, "dsmadmc -id=view -password=view 'query libvol' | grep 'Scratch' | wc -l |";
+ while (<IN>) {
+ chomp;
+ @fld = split(/ +/,);
+ if (/\d/) {
+ $tsmscr = $fld[1];
+ }
+ }
+ close IN;
+
+ $tsmvlt = 0;
+ open IN, "dsmadmc -id=view -password=view 'query drmedia' | grep 'Vault' | wc -l |";
+ while (<IN>) {
+ chomp;
+ @fld = split(/ +/,);
+ if (/\d/) {
+ $tsmvlt = $fld[1];
+ }
+ }
+
+ $tsm_tape_info = join "\t", $tsmpvt, $tsmscr, $tsmvlt;
+ $tsm_tape_header = join "\t", tsmpvt, tsmscr, tsmvlt;
+
+ if ( scalar( split ' ', $tsm_tape_header ) !=
+ scalar( split ' ', $tsm_tape_info ) )
+ {
+ print STDERR "WARNING: TSM Tape header does not match TSM Tape info.\n";
+ $tsm_tape_header = '';
+ $tsm_tape_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TSM Disk Storage Pool usage
+ $tsmphcy = 0;
+ $tsmphcn = 0;
+ open IN, "dsmadmc -id=view -password=view 'query stgpool' |";
+ while (<IN>) {
+ @fld = split(/ +/,);
+ if (/\d/) {
+ if ( $fld[0] eq "PHCYDISKPO-" ) {
+ $tsmphcy = $fld[3];
+ }
+ elsif ( $fld[0] eq "PHCNDISKPO-" ) {
+ $tsmphcn = $fld[3];
+ }
+ }
+ }
+ close IN;
+
+ $tsm_stg_info = join "\t", $tsmphcy, $tsmphcn;
+ $tsm_stg_header = join "\t", tsmphcy, tsmphcn;
+
+ if ( scalar( split ' ', $tsm_stg_header ) !=
+ scalar( split ' ', $tsm_stg_info ) )
+ {
+ print STDERR "WARNING: TSM Storage Pool header does not match TSM Storage Pool info.\n";
+ $tsm_stg_header = '';
+ $tsm_stg_info = '';
+ $need_header = 1;
+ }
+
+ ## Join header and info then verify column counts.
+ $out_header = join "\t", "timestamp", "locltime", $load_header, $up_header,
+ $proc_header, $vmstat_header, $fs_header, $iostat_header, $packet_header,
+ $tcp_header, $tsm_header, $swap_header, $mem_header, $tsm_rmt_header,
+ $tsm_log_header, $tsm_tape_header, $tsm_stg_header;
+ $out_header =~ tr/ \t/\t/s; # translate whitespace to single tabs
+
+ $out_info = join "\t", $timestamp, $locltime, $load_info, $up_info, $proc_info,
+ $vmstat_info, $fs_info, $iostat_info, $packet_info, $tcp_info, $tsm_info,
+ $swap_info, $mem_info, $tsm_rmt_info, $tsm_log_info, $tsm_tape_info,
+ $tsm_stg_info;
+ $out_info =~ tr/ \t/\t/s; # translate whitespace to single tabs
+
+ $header_cnt = split ' ', $out_header;
+ $info_cnt = split ' ', $out_info;
+ if ( $header_cnt != $info_cnt ) {
+ print STDERR
+ "ERROR: header columns do not equal data columns. Exiting.\n";
+ &exit_nicely;
+ }
+ elsif ( $header_cnt != $prev_header_cnt or $info_cnt != $prev_info_cnt ) {
+ $need_header = 1;
+ }
+ $prev_header_cnt = $header_cnt;
+ $prev_info_cnt = $info_cnt;
+
+ ## Write output
+ if ($need_header) {
+ print OUT $out_header, "\n";
+ $need_header = 0;
+ }
+ print OUT $out_info, "\n";
+
+ sleep $INTERVAL - ( time() - $timestamp );
+
+}
+close OUT;
+
+ at args = ( "/usr/local/bin/gzip", "-f", "$stat_file" );
+system(@args);
+
+exit 0;
+
+# This subroutine is called by the signal handler.
+sub exit_nicely {
+ close OUT;
+ @args = ( "/usr/local/bin/gzip", "-f", "$stat_file" );
+ system(@args);
+ exit 0;
+}
Added: trunk/orca/data_gatherers/aix/orcallatorAIX.cfg
==============================================================================
--- (empty file)
+++ trunk/orca/data_gatherers/aix/orcallatorAIX.cfg Sat Apr 3 16:07:15 2004
@@ -0,0 +1,825 @@
+# Orca configuration file for orcallator files.
+
+# $HeadURL$
+# $LastChangedDate$
+# $LastChangedBy$
+# $LastChangedRevision$
+
+# Require at least this version of Orca.
+require Orca 0.265
+
+# base_dir is prepended to the paths find_files, html_dir, rrd_dir,
+# and state_file only if the path does not match the regular
+# expression ^\\?\.{0,2}/, which matches /, ./, ../, and \./.
+base_dir /opt/orca/var/orca/orca-aix
+
+# rrd_dir specifies the location of the generated RRD data files. If
+# rrd_dir is a relative path, then it is made relative to base_dir if
+# base_dir is set.
+rrd_dir .
+
+# state_file specifies the location of the state file that remembers
+# the modification time of each source data file. If state_file is a
+# relative path, then it is made relative to base_dir is base_dir is
+# set.
+state_file orca.state
+
+# html_dir specifies the top of the HTML tree created by Orca.
+html_dir /opt/orca/html/orcallator
+
+# By default create .meta tag files for all PNGs or GIFs so that the
+# web browser will automatically reload them.
+expire_images 1
+
+# Find files at the following times:
+# 0:10 to pick up new orcallator files for the new day.
+# 1:00 to pick up late comer orcallator files for the new day.
+# 6:00 to pick up new files before the working day.
+# 12:00 to pick up new files during the working day.
+# 19:00 to pick up new files after the working day.
+find_times 0:10 1:00 6:00 12:00 19:00
+
+# This defines the email address of people to warn when a file that is
+# being updated constantly stops being updated. For mathematical
+# expressions use the word `interval' to get the interval number for
+# the data source.
+#warn_email rajesh.verma at palmettohealth.org
+late_interval interval + 30
+
+# These parameters specify which plots to generate.
+generate_hourly_plot 1
+generate_daily_plot 1
+generate_weekly_plot 1
+generate_monthly_plot 1
+generate_quarterly_plot 1
+generate_yearly_plot 1
+
+# This sets the HTML markup that is placed at the very top of every
+# web page and is primarly used to display the site's logo.
+html_page_header
+ <tr>
+ </tr>
+
+# This sets the text that is placed in the pages' <title></title>
+# element and just after the html_page_header HTML markup text is
+# placed on the page.
+html_top_title Palmetto Health IBM-AIX Host Status
+
+# This sets the HTML markup that is placed at the bottom of every web
+# page.
+html_page_footer
+ <font face="verdana,geneva,arial,helvetica">
+ These plots brought to you by your Unix System Administrator.
+ </font>
+
+# This defines where the find the source data files and the format of
+# those files. Notes about the fields:
+# find_files
+# You'll notice that all but the first () has the form (?:...).
+# This tells Perl to match the expression but not save the matched
+# text in the $1, $2, variables. Orca uses the matched text to
+# generate a subgroup name, which is used to place files into
+# different subgroups. Here, only the hostname should be used to
+# generate a subgroup name, hence all the (?:...) for matching
+# anything else.
+# interval
+# The interval here must match the interval used by orcallator to
+# record data. Do not change this, as it has an effect on the
+# generated RRD data files.
+
+group orcallator {
+find_files /opt/orca/var/orca/orca-aix/(.*)/(?:(?:orcallator)|(?:percol))-\d{4}-\d{2}-\d{2}(?:-\d{3,})?(?:\.(?:Z|gz|bz2))?
+column_description first_line
+date_source column_name timestamp
+interval 300
+filename_compare sub {
+ my ($ay, $am, $ad) = $a =~ /-(\d{4})-(\d\d)-(\d\d)/;
+ my ($by, $bm, $bd) = $b =~ /-(\d{4})-(\d\d)-(\d\d)/;
+ if (my $c = (( $ay <=> $by) ||
+ ( $am <=> $bm) ||
+ (($ad >> 3) <=> ($bd >> 3)))) {
+ return 2*$c;
+ }
+ $ad <=> $bd;
+ }
+}
+
+plot {
+title %g System Overview
+source orcallator
+data state_c / 2
+data state_D / 2
+data state_N / 2
+data state_t / 2
+data state_n / 2
+data state_s / 2
+data state_r / 2
+data state_k / 2
+data state_m / 2
+data state_d / 2
+data state_i / 2
+line_type line3
+summary_format %8.2lf %S
+legend CPU power
+legend Disk
+legend Network
+legend TCP/IP stack
+legend NFS RPC client
+legend Swap space
+legend RAM demand
+legend Kernel memory
+legend Kernel contention
+legend DNLC
+legend Inode cache
+y_legend Severity level
+data_min 0
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#system_overview
+}
+
+
+plot {
+title %g Average # Processes in Run Queue (Load Average)
+source orcallator
+data 1runq
+data 5runq
+data 15runq
+legend 1 minute average
+legend 5 minute average
+legend 15 minute average
+y_legend Number Processes
+data_min 0
+data_max 1000
+href http://www.orcaware.com/orca/docs/orcallator.html#processes_in_run_queue
+}
+
+plot {
+title %g CPU Usage
+source orcallator
+data usr%
+data sys%
+data wio%
+data idle%
+line_type area
+line_type stack
+line_type stack
+line_type stack
+legend User
+legend System
+legend Wait IO
+legend Idle
+y_legend Percent
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+rigid_min_max 1
+href http://www.orcaware.com/orca/docs/orcallator.html#cpu_usage
+}
+
+plot {
+title %g Processes in Run Queue/Waiting/Swapped
+source orcallator
+data runque
+data waiting
+line_type area
+line_type stack
+legend processes in run queue
+legend processes waiting for IO
+y_legend Number Processes
+data_min 0
+}
+
+plot {
+title %g Memory Free
+source orcallator
+data 4096 * pagestotl - 4096 * pagesfree
+data 4096 * pagesfree
+line_type area
+line_type stack
+legend Used Physical memory
+legend Free physical memory
+y_legend Bytes/s
+base 1024
+data_min 0
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#memory_free
+}
+
+plot {
+title %g Memory Usage Breakup in Bytes
+source orcallator
+data mem_work
+data mem_pres
+data mem_clnt
+line_type area
+line_type stack
+line_type stack
+legend Working Segment
+legend Presistent Segment
+legend Client Segment
+y_legend Number Of Bytes
+data_min 0
+plot_min 0
+color 00ff00
+color ff0000
+color 0000ff
+href http://www.orcaware.com/orca/docs/orcallator.html#page_usage
+}
+
+plot {
+title %g Available Swap Space in Bytes
+source orcallator
+data swap_used
+data swap_free
+line_type area
+line_type stack
+legend Used swap space
+legend Free swap space
+y_legend Bytes
+base 1024
+data_min 0
+data_min 1000000000
+href http://www.orcaware.com/orca/docs/orcallator.html#available_swap_space
+}
+
+plot {
+title %g Memory Page Scan Rate
+source orcallator
+data scanrate
+line_type area
+legend Page scan rate
+y_legend Pages/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#page_scan_rate
+}
+
+plot {
+plot_width 580
+title %g Disk Space Percent Usage
+source orcallator
+data mntP_(.*)
+line_type line2
+legend $1
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_space_percent_usage
+}
+
+plot {
+title %g Disk Inode Percent Usage
+source orcallator
+data mntp_(.*)
+line_type line2
+legend $1
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_inode_percent_usage
+}
+
+plot {
+title %g Disk System Wide Reads/Writes Per Second
+source orcallator
+data 1024 * disk_rK/s
+data 1024 * disk_wK/s
+line_type area
+line_type line1
+legend Data Read/s
+legend Data Write/s
+y_legend Bytes/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_system_wide_reads_writes_per_second
+}
+
+plot {
+title %g Disk System Wide Transfer Rate
+source orcallator
+data disk_t/s
+line_type area
+legend Number of transfer/s
+y_legend Bytes/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_system_wide_transfer_rate
+}
+
+plot {
+title %g Number of Users
+source orcallator
+data nusr
+line_type area
+legend Number of Users/s
+y_legend Users
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_system_wide_transfer_rate
+}
+
+plot {
+title %g System Uptime
+source orcallator
+data uptime /86400
+line_type area
+legend Number of Day/s
+y_legend Days
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#system_uptime
+}
+
+plot {
+title %g TCP Number Open Connections
+source orcallator
+data tcp_estb
+line_type area
+legend # open connections
+y_legend Number Open TCP Connections
+data_min 0
+data_max 50000
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_number_open_connections
+}
+
+plot {
+title %g New Process Spawn Rate
+source orcallator
+data #proc/s
+data #proc/p5s
+line_type area
+line_type line1
+legend 5 min average
+legend Peak 5 second
+y_legend New processes/s
+data_min 0
+data_max 100000
+href http://www.orcaware.com/orca/docs/orcallator.html#new_process_spawn_rate
+}
+
+plot {
+title %g Number of System & Web Server Processes
+source orcallator
+data #proc
+data #httpds
+line_type line1
+line_type area
+legend System total
+legend Number web servers
+y_legend Number Processes
+data_min 0
+data_max 10000
+color 0000ff
+color 00ff00
+href http://www.orcaware.com/orca/docs/orcallator.html#number_system_processes
+}
+
+plot {
+title %g Number of Web Server Processes
+source orcallator
+data #httpds
+line_type area
+legend Number web servers
+y_legend Number Processes
+data_min 0
+data_max 10000
+href http://www.orcaware.com/orca/docs/orcallator.html#number_web_server_processes
+}
+
+plot {
+title %g Web Server Hit Rate
+source orcallator
+data httpop/s
+data http/p5s
+line_type area
+line_type line1
+legend 5 min average hits/s
+legend Peak 5 second hits/s
+y_legend Hits/s
+data_min 0
+color 00ff00
+color 0000ff
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_hit_rate
+}
+
+plot {
+title %g Web Server File Size
+source orcallator
+data %to1KB
+data %to10KB
+data %to100KB
+data %to1MB
+data %over1MB
+line_type area
+line_type stack
+line_type stack
+line_type stack
+line_type stack
+legend 0 - 1 KB
+legend 1 - 10 KB
+legend 10 - 100 KB
+legend 100 - 1000 KB
+legend Greater than 1 MB
+y_legend Percent
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+rigid_min_max 1
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_file_size
+}
+
+plot {
+title %g Web Server Data Transfer Rate
+source orcallator
+data httpb/s
+line_type area
+legend Bytes/s
+y_legend Bytes/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_data_transfer_rate
+}
+
+plot {
+title %g Web Server HTTP Error Rate
+source orcallator
+data htErr/s
+line_type area
+legend HTTP errors/s
+y_legend Errors/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_error_rate
+}
+
+# Interface bits per second for 10 Mbit interfaces.
+#plot {
+#title %g Interface Bits Per Second: $1
+#source orcallator
+#data 1024 * 8 * ((?:(?:elxl)|(?:le)|(?:qe))\d+)InKB/s
+#data 1024 * 8 * $1OuKB/s
+#line_type area
+#line_type line1
+#legend Input
+#legend Output
+#y_legend Bits/s
+#data_min 0
+#data_max 10000000
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_bits_per_second
+#}
+#
+## Interface bits per second for 100 Mbit interfaces.
+#plot {
+#title %g Interface Bits Per Second: $1
+#source orcallator
+#data 1024 * 8 * ((?:(?:be)|(?:dmfe)|(?:eri)|(?:hme)|(?:qfe)|(?:znb))\d+)InKB/s
+#data 1024 * 8 * $1OuKB/s
+#line_type area
+#line_type line1
+#legend Input
+#legend Output
+#y_legend Bits/s
+#data_min 0
+#data_max 100000000
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_bits_per_second
+#}
+#
+## Interface bits per second for 1 Gbit interfaces.
+#plot {
+#title %g Interface Bits Per Second: $1
+#source orcallator
+#data 1024 * 8 * ((?:(?:ce)|(?:v?ge)|(?:skge))\d+)InKB/s
+#data 1024 * 8 * $1OuKB/s
+#line_type area
+#line_type line1
+#legend Input
+#legend Output
+#y_legend Bits/s
+#data_min 0
+#data_max 1000000000
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_bits_per_second
+#}
+
+#plot {
+#title %g Interface Packets Per Second: $1
+#source orcallator
+#data (.*\d+)Ipkt/s
+#data $1Opkt/s
+#line_type area
+#line_type stack
+#legend Input
+#legend Output
+#y_legend Packets/s
+#data_min 5000
+#data_max 1000000000
+#flush_regexps 1
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_packets_per_second
+#}
+
+#plot {
+#title %g Interface Errors Per Second: $1
+#source orcallator
+#data (.*\d+)IErr/s
+#data $1OErr/s
+#line_type area
+#line_type stack
+#legend Input
+#legend Output
+#y_legend Errors/s
+#data_min 0
+#data_max 1000000000
+#flush_regexps 1
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_errors_per_second
+#}
+#
+#plot {
+#title %g Interface Deferred Packet Rate
+#source orcallator
+#data (.*\d+)Defr/s
+#line_type area
+#legend $1
+#y_legend Defers/s
+#data_min 0
+#flush_regexps 1
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_deferred_packet_rate
+#}
+
+#plot {
+#title %g Interface Collisions: $1
+#source orcallator
+#data (.*\d+)Coll%
+#line_type area
+#legend $1
+#y_legend Percent
+#data_min 0
+#data_max 200
+#flush_regexps 1
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_collisions
+#}
+
+#plot {
+#title %g Interface Nocanput Rate
+#source orcallator
+#data (.*\d+)NoCP/s
+#line_type area
+#legend $1
+#y_legend Nocanput/s
+#data_min 0
+#flush_regexps 1
+#href http://www.orcaware.com/orca/docs/orcallator.html#interface_nocanput_rate
+#}
+#
+#plot {
+#title %g TCP Bits Per Second
+#source orcallator
+#data 1024 * 8 * tcp_InKB/s
+#data 1024 * 8 * tcp_OuKB/s
+#line_type area
+#line_type line1
+#legend Input
+#legend Output
+#y_legend Bits/s
+#data_min 0
+#data_max 1000000000
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_bits_per_second
+#}
+#
+#plot {
+#title %g TCP Segments Per Second
+#source orcallator
+#data tcp_Iseg/s
+#data tcp_Oseg/s
+#line_type area
+#line_type line1
+#legend Input
+#legend Output
+#y_legend Segments/s
+#data_min 0
+#data_max 20000
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_segments_per_second
+#}
+
+#plot {
+#title %g TCP Retransmission & Duplicate Received Percentage
+#source orcallator
+#data tcp_Ret%
+#data tcp_Dup%
+#line_type area
+#line_type line1
+#legend Retransmission
+#legend Duplicate received
+#y_legend Percent
+#data_min 0
+#data_max 200
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_retransmission_duplicate_received_percentage
+#}
+#
+#plot {
+#title %g TCP New Connection Rate
+#source orcallator
+#data tcp_Icn/s
+#data tcp_Ocn/s
+#line_type area
+#line_type line1
+#legend Input - passive
+#legend Output - active
+#y_legend New Connections/s
+#data_min 0
+#data_max 10000
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_new_connection_rate
+#}
+#
+
+#plot {
+#title %g TCP Reset Rate
+#source orcallator
+#data tcp_Rst/s
+#line_type area
+#legend Number TCP resets/s
+#y_legend Resets/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_reset_rate
+#}
+#
+#plot {
+#title %g TCP Attempt Fail Rate
+#source orcallator
+#data tcp_Atf/s
+#line_type area
+#legend TCP attempt fails/s
+#y_legend TCP Attempt Fails/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_attempt_fail_rate
+#}
+#
+#plot {
+#title %g TCP Listen Drop Rate
+#source orcallator
+#data tcp_Ldrp/s
+#data tcp_LdQ0/s
+#data tcp_HOdp/s
+#legend TCP listen drops
+#legend TCP listen drop Q0
+#legend TCP half open drops
+#y_legend TCP Listen Drops/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#TCP_listen_drop_rate
+#}
+
+#plot {
+#title %g Sleeps on Mutex Rate
+#source orcallator
+#data smtx
+#data smtx/cpu
+#line_type area
+#line_type line1
+#legend Sleeps on mutex
+#legend Sleeps on mutex/cpu
+#y_legend Sleeps on Mutex/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#sleeps_mutex_rate
+#}
+#
+#plot {
+#title %g NFS Server Call Rate
+#source orcallator
+#data nfss_calls
+#data v2reads
+#data v2writes
+#data v3reads
+#data v3writes
+#data nfss_bad
+#data_type counter
+#line_type area
+#line_type area
+#line_type stack
+#line_type stack
+#line_type stack
+#line_type stack
+#legend NFS server calls/s
+#y_legend NFS Server Calls/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#NFS_server_call_rate
+#}
+#
+#plot {
+#title %g NFS Server Call Distribution
+#source orcallator
+#data v2reads
+#data v2writes
+#data v3reads
+#data v3writes
+#data_type counter
+#line_type area
+#line_type stack
+#line_type stack
+#line_type stack
+#line_type stack
+#y_legend NFS Server Calls/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#NFS_server_call_distribution
+#}
+#
+#plot {
+#title %g NFS Client Call Rate
+#source orcallator
+#data nfs_call/s
+#line_type area
+#legend NFS client calls/s
+#y_legend NFS Client Calls/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#NFS_client_call_rate
+#}
+#
+#plot {
+#title %g NFS Timeouts & Bad Transmits Rate
+#source orcallator
+#data nfs_timo/s
+#data nfs_badx/s
+#line_type area
+#line_type line1
+#legend NFS timeouts
+#legend Bad transmits
+#y_legend Count/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#NFS_timeouts_bad_transmits_rate
+#}
+#
+##plot {
+##title %g Disk Run Percent
+##source orcallator
+##data disk_runp_((?:c\d+t\d+d\d+)|(?:c\d+d\d+)|(?:[ms]d\d+))
+##line_type line2
+##legend $1
+##y_legend Run Percent
+##data_min 0
+#data_max 100
+#plot_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#disk_run_percent
+#}
+
+#plot {
+#title %g Cache Hit Percentages
+#source orcallator
+#data dnlc_hit%
+#data inod_hit%
+#line_type area
+#line_type line1
+#legend DNLC
+#legend Inode cache
+#y_legend Percent
+#data_min 0
+#data_max 100
+#href http://www.orcaware.com/orca/docs/orcallator.html#cache_hit_percentages
+#}
+#
+#plot {
+#title %g Cache Reference Rate
+#source orcallator
+#data dnlc_ref/s
+#data inod_ref/s
+#line_type area
+#line_type line1
+#legend DNLC
+#legend Inode cache
+#y_legend References/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#cache_reference_rate
+#}
+#
+#plot {
+#title %g Cache Inode Steal Rate
+#source orcallator
+#data inod_stl/s
+#line_type area
+#legend Inode w/page steals/s
+#y_legend Steals/s
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#inode_steal_rate
+#}
+#
+#
+#plot {
+#title %g Memory Page Residence Time
+#source orcallator
+#data page_rstim
+#line_type area
+#legend Page residence time
+#y_legend Seconds
+#data_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#page_residence_time
+#}
+
+plot {
+title %g Memory Pages Locked & IO
+source orcallator
+data pageslock
+data pagesio
+line_type area
+line_type line1
+legend Locked
+legend IO
+y_legend Number Of Pages
+data_min 0
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#pages_locked_IO
+}
+
Added: trunk/orca/data_gatherers/aix/orcallatorTSM.cfg
==============================================================================
--- (empty file)
+++ trunk/orca/data_gatherers/aix/orcallatorTSM.cfg Sat Apr 3 16:07:15 2004
@@ -0,0 +1,193 @@
+# Orca configuration file for orcallator files.
+
+# $HeadURL$
+# $LastChangedDate$
+# $LastChangedBy$
+# $LastChangedRevision$
+
+# Require at least this version of Orca.
+require Orca 0.265
+
+# base_dir is prepended to the paths find_files, html_dir, rrd_dir,
+# and state_file only if the path does not match the regular
+# expression ^\\?\.{0,2}/, which matches /, ./, ../, and \./.
+base_dir /opt/orcaTSM/var/orca/orcallator
+
+# rrd_dir specifies the location of the generated RRD data files. If
+# rrd_dir is a relative path, then it is made relative to base_dir if
+# base_dir is set.
+rrd_dir .
+
+# state_file specifies the location of the state file that remembers
+# the modification time of each source data file. If state_file is a
+# relative path, then it is made relative to base_dir is base_dir is
+# set.
+state_file orca.state
+
+# html_dir specifies the top of the HTML tree created by Orca.
+html_dir /opt/orcaTSM/html/orcallator
+
+# By default create .meta tag files for all PNGs or GIFs so that the
+# web browser will automatically reload them.
+expire_images 1
+
+# Find files at the following times:
+# 0:10 to pick up new orcallator files for the new day.
+# 1:00 to pick up late comer orcallator files for the new day.
+# 6:00 to pick up new files before the working day.
+# 12:00 to pick up new files during the working day.
+# 19:00 to pick up new files after the working day.
+find_times 0:10 1:00 6:00 12:00 19:00
+
+# This defines the email address of people to warn when a file that is
+# being updated constantly stops being updated. For mathematical
+# expressions use the word `interval' to get the interval number for
+# the data source.
+#warn_email rajesh.verma at palmettohealth.org
+late_interval interval + 30
+
+# These parameters specify which plots to generate.
+generate_hourly_plot 1
+generate_daily_plot 1
+generate_weekly_plot 1
+generate_monthly_plot 1
+generate_quarterly_plot 1
+generate_yearly_plot 1
+
+# This sets the HTML markup that is placed at the very top of every
+# web page and is primarly used to display the site's logo.
+html_page_header
+ <tr>
+ </tr>
+
+# This sets the text that is placed in the pages' <title></title>
+# element and just after the html_page_header HTML markup text is
+# placed on the page.
+html_top_title Palmetto Health IBM-TSM Host Status
+
+# This sets the HTML markup that is placed at the bottom of every web
+# page.
+html_page_footer
+ <font face="verdana,geneva,arial,helvetica">
+ These plots brought to you by your Unix System Administrator.
+ </font>
+
+# This defines where the find the source data files and the format of
+# those files. Notes about the fields:
+# find_files
+# You'll notice that all but the first () has the form (?:...).
+# This tells Perl to match the expression but not save the matched
+# text in the $1, $2, variables. Orca uses the matched text to
+# generate a subgroup name, which is used to place files into
+# different subgroups. Here, only the hostname should be used to
+# generate a subgroup name, hence all the (?:...) for matching
+# anything else.
+# interval
+# The interval here must match the interval used by orcallator to
+# record data. Do not change this, as it has an effect on the
+# generated RRD data files.
+
+group orcallator {
+find_files /opt/orcaTSM/var/orca/orcallator/(.*)/(?:(?:orcallator)|(?:percol))-\d{4}-\d{2}-\d{2}(?:-\d{3,})?(?:\.(?:Z|gz|bz2))?
+#find_files /opt/orcaTSM/var/orca/orcallator/(.*)/(?:(?:orcallator)|(?:percol))-\d{4}-\d{2}-\d{2}-\d{3}?(?:\.(?:Z|gz|bz2))?
+column_description first_line
+date_source column_name timestamp
+interval 300
+filename_compare sub {
+ my ($ay, $am, $ad) = $a =~ /-(\d{4})-(\d\d)-(\d\d)/;
+ my ($by, $bm, $bd) = $b =~ /-(\d{4})-(\d\d)-(\d\d)/;
+ if (my $c = (( $ay <=> $by) ||
+ ( $am <=> $bm) ||
+ (($ad >> 3) <=> ($bd >> 3)))) {
+ return 2*$c;
+ }
+ $ad <=> $bd;
+ }
+}
+
+plot {
+title %g TSM Tape Drive Usage
+source orcallator
+data rmt
+data rmt5
+line_type area
+line_type line2
+legend Number of Tape Drive Requests
+legend Number of Physical Tape Drives
+y_legend Tape Drives
+data_min 0
+plot_min 0
+color 00ff00
+color ff0000
+href http://www.orcaware.com/orca/docs/orcallator.html#tsm_db_space_percent_usage
+}
+
+plot {
+title %g TSM Database Space Percent Usage
+source orcallator
+data tsmdb
+line_type area
+legend TSM Database
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#tsm_db_space_percent_usage
+}
+
+plot {
+title %g TSM Recovery Log Space Percent Usage
+source orcallator
+data tsmlog
+line_type area
+legend TSM Recovery Log
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#tsm_db_space_percent_usage
+}
+
+plot {
+title %g TSM Tape Usage
+source orcallator
+data tsmvlt
+data tsmpvt
+#data tsmvlt + tsmpvt
+data tsmscr
+data tsmvlt + tsmpvt + tsmscr
+line_type area
+line_type stack
+#line_type line1
+line_type stack
+line_type line1
+legend In Use in Vault
+legend In Use in Library
+#legend Total in Use
+legend Scratch in Library
+legend Total Tapes
+y_legend Number of Tapes
+data_min 0
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#cpu_usage
+}
+
+plot {
+title %g TSM Storage Pool Percent Usage
+source orcallator
+data tsmphcy
+data tsmphcn
+line_type line2
+line_type line2
+legend TSM Colocate=Yes Storage Pool
+legend TSM Colocate=No Storage Pool
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#tsm_db_space_percent_usage
+}
+
Added: trunk/orca/data_gatherers/hp/hporcallator.cfg
==============================================================================
--- (empty file)
+++ trunk/orca/data_gatherers/hp/hporcallator.cfg Sat Apr 3 16:07:15 2004
@@ -0,0 +1,827 @@
+# Orca configuration file for orcallator files.
+
+# $HeadURL$
+# $LastChangedDate$
+# $LastChangedBy$
+# $LastChangedRevision$
+
+# Require at least this version of Orca.
+require Orca 0.265
+
+# base_dir is prepended to the paths find_files, html_dir, rrd_dir,
+# and state_file only if the path does not match the regular
+# expression ^\\?\.{0,2}/, which matches /, ./, ../, and \./.
+base_dir /opt/orcaHP/var/orca/orcallator
+
+# rrd_dir specifies the location of the generated RRD data files. If
+# rrd_dir is a relative path, then it is made relative to base_dir if
+# base_dir is set.
+rrd_dir .
+
+# state_file specifies the location of the state file that remembers
+# the modification time of each source data file. If state_file is a
+# relative path, then it is made relative to base_dir is base_dir is
+# set.
+state_file orca.state
+
+# html_dir specifies the top of the HTML tree created by Orca.
+html_dir /opt/orcaHP/html/orcallator
+
+# By default create .meta tag files for all PNGs or GIFs so that the
+# web browser will automatically reload them.
+expire_images 1
+
+# Find files at the following times:
+# 0:10 to pick up new orcallator files for the new day.
+# 1:00 to pick up late comer orcallator files for the new day.
+# 6:00 to pick up new files before the working day.
+# 12:00 to pick up new files during the working day.
+# 19:00 to pick up new files after the working day.
+find_times 0:10 1:00 6:00 12:00 19:00
+
+# This defines the email address of people to warn when a file that is
+# being updated constantly stops being updated. For mathematical
+# expressions use the word `interval' to get the interval number for
+# the data source.
+warn_email rajesh.verma at palmettohealth.org
+late_interval interval + 30
+
+# These parameters specify which plots to generate.
+generate_hourly_plot 1
+generate_daily_plot 1
+generate_weekly_plot 1
+generate_monthly_plot 1
+generate_quarterly_plot 1
+generate_yearly_plot 1
+
+# This sets the HTML markup that is placed at the very top of every
+# web page and is primarly used to display the site's logo.
+html_page_header
+ <tr>
+ </tr>
+
+# This sets the text that is placed in the pages' <title></title>
+# element and just after the html_page_header HTML markup text is
+# placed on the page.
+html_top_title Palmetto Health HP-UX Host Status
+
+# This sets the HTML markup that is placed at the bottom of every web
+# page.
+html_page_footer
+ <font face="verdana,geneva,arial,helvetica">
+ These plots brought to you by your Unix System Administrator.
+ </font>
+
+# This defines where the find the source data files and the format of
+# those files. Notes about the fields:
+# find_files
+# You'll notice that all but the first () has the form (?:...).
+# This tells Perl to match the expression but not save the matched
+# text in the $1, $2, variables. Orca uses the matched text to
+# generate a subgroup name, which is used to place files into
+# different subgroups. Here, only the hostname should be used to
+# generate a subgroup name, hence all the (?:...) for matching
+# anything else.
+# interval
+# The interval here must match the interval used by orcallator to
+# record data. Do not change this, as it has an effect on the
+# generated RRD data files.
+
+group orcallator {
+find_files /opt/orcaHP/var/orca/orcallator/(.*)/(?:(?:orcallator)|(?:percol))-\d{4}-\d{2}-\d{2}(?:-\d{3,})?(?:\.(?:Z|gz|bz2))?
+column_description first_line
+date_source column_name timestamp
+interval 300
+filename_compare sub {
+ my ($ay, $am, $ad) = $a =~ /-(\d{4})-(\d\d)-(\d\d)/;
+ my ($by, $bm, $bd) = $b =~ /-(\d{4})-(\d\d)-(\d\d)/;
+ if (my $c = (( $ay <=> $by) ||
+ ( $am <=> $bm) ||
+ (($ad >> 3) <=> ($bd >> 3)))) {
+ return 2*$c;
+ }
+ $ad <=> $bd;
+ }
+}
+
+plot {
+title %g System Overview
+source orcallator
+data state_c / 2
+data state_D / 2
+data state_N / 2
+data state_t / 2
+data state_n / 2
+data state_s / 2
+data state_r / 2
+data state_k / 2
+data state_m / 2
+data state_d / 2
+data state_i / 2
+line_type line3
+summary_format %8.2lf %S
+legend CPU power
+legend Disk
+legend Network
+legend TCP/IP stack
+legend NFS RPC client
+legend Swap space
+legend RAM demand
+legend Kernel memory
+legend Kernel contention
+legend DNLC
+legend Inode cache
+y_legend Severity level
+data_min 0
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#system_overview
+}
+
+plot {
+title %g System Uptime
+source orcallator
+data uptime
+legend Uptime
+y_legend Days
+data_min 0
+data_max 1000
+href http://www.orcaware.com/orca/docs/orcallator.html#system_uptime
+}
+
+plot {
+title %g Average # Processes in Run Queue (Load Average)
+source orcallator
+data 1runq
+data 5runq
+data 15runq
+legend 1 minute average
+legend 5 minute average
+legend 15 minute average
+y_legend Number Processes
+data_min 0
+data_max 1000
+href http://www.orcaware.com/orca/docs/orcallator.html#processes_in_run_queue
+}
+
+plot {
+title %g CPU Usage
+source orcallator
+data usr%
+data sys%
+data wio%
+data idle%
+line_type area
+line_type stack
+line_type stack
+line_type stack
+legend User
+legend System
+legend Wait IO
+legend Idle
+y_legend Percent
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+rigid_min_max 1
+href http://www.orcaware.com/orca/docs/orcallator.html#cpu_usage
+}
+
+#plot {
+#title %g Processes in Run Queue/Waiting/Swapped
+#source orcallator
+#data #runque
+#data waiting
+#line_type area
+#line_type stack
+#legend processes in run queue
+#legend processes waiting for IO
+#y_legend Number Processes
+#data_min 0
+#}
+
+plot {
+title %g Memory Free
+source orcallator
+data 4096 * free_pages
+line_type area
+legend Free physical memory
+y_legend Bytes
+base 1024
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#memory_free
+}
+
+plot {
+title %g Memory Usage Breakup
+source orcallator
+data mem_work
+data mem_pres
+data mem_clnt
+data mem_work + mem_pres + mem_clnt
+line_type area
+line_type stack
+line_type stack
+line_type line2
+legend Working Segment
+legend Presistent Segment
+legend Clinet Segment
+legend Total Memory Used
+y_legend Number Of Pages
+data_min 0
+plot_min 0
+color 00ff00
+color ff0000
+color 0000ff
+href http://www.orcaware.com/orca/docs/orcallator.html#page_usage
+}
+
+plot {
+title %g Available Swap Space in Bytes
+source orcallator
+data swap_used
+data swap_free
+data swap_free + swap_free
+line_type area
+line_type stack
+line_type stack
+legend Available swap space
+legend Available swap space
+legend Available swap space
+y_legend Bytes
+base 1024
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#available_swap_space
+}
+
+
+plot {
+title %g Disk Space Percent Usage
+source orcallator
+data mntP_(.*)
+line_type line2
+legend $1
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_space_percent_usage
+}
+
+plot {
+title %g Disk Inode Percent Usage
+source orcallator
+data mntp_(.*)
+line_type line2
+legend $1
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_inode_percent_usage
+}
+
+plot {
+title %g Disk System Wide Reads/Writes Per Second
+source orcallator
+data 1024 * disk_rK/s
+data 1024 * disk_wK/s
+line_type area
+line_type line1
+legend Data Read/s
+legend Data Write/s
+y_legend Bytes/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_system_wide_reads_writes_per_second
+}
+
+plot {
+title %g Disk System Wide Transfer Rate
+source orcallator
+data disk_t/s
+line_type area
+legend Number of transfer/s
+y_legend Bytes/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#disk_system_wide_transfer_rate
+}
+
+plot {
+title %g TSM Database Space Percent Usage
+source orcallator
+data tsmdb
+line_type stack
+legend TSM Database
+y_legend Percent Used
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#tsm_db_space_percent_usage
+}
+
+plot {
+title %g New Process Spawn Rate
+source orcallator
+data #proc/s
+data #proc/p5s
+line_type area
+line_type line1
+legend 5 min average
+legend Peak 5 second
+y_legend New processes/s
+data_min 0
+data_max 100000
+href http://www.orcaware.com/orca/docs/orcallator.html#new_process_spawn_rate
+}
+
+plot {
+title %g Number of System & Web Server Processes
+source orcallator
+data #proc
+data #httpds
+line_type line1
+line_type area
+legend System total
+legend Number web servers
+y_legend Number Processes
+data_min 0
+data_max 10000
+color 0000ff
+color 00ff00
+href http://www.orcaware.com/orca/docs/orcallator.html#number_system_processes
+}
+
+plot {
+title %g Number of Web Server Processes
+source orcallator
+data #httpds
+line_type area
+legend Number web servers
+y_legend Number Processes
+data_min 0
+data_max 10000
+href http://www.orcaware.com/orca/docs/orcallator.html#number_web_server_processes
+}
+
+plot {
+title %g Web Server Hit Rate
+source orcallator
+data httpop/s
+data http/p5s
+line_type area
+line_type line1
+legend 5 min average hits/s
+legend Peak 5 second hits/s
+y_legend Hits/s
+data_min 0
+color 00ff00
+color 0000ff
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_hit_rate
+}
+
+plot {
+title %g Web Server File Size
+source orcallator
+data %to1KB
+data %to10KB
+data %to100KB
+data %to1MB
+data %over1MB
+line_type area
+line_type stack
+line_type stack
+line_type stack
+line_type stack
+legend 0 - 1 KB
+legend 1 - 10 KB
+legend 10 - 100 KB
+legend 100 - 1000 KB
+legend Greater than 1 MB
+y_legend Percent
+data_min 0
+data_max 100
+plot_min 0
+plot_max 100
+rigid_min_max 1
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_file_size
+}
+
+plot {
+title %g Web Server Data Transfer Rate
+source orcallator
+data httpb/s
+line_type area
+legend Bytes/s
+y_legend Bytes/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_data_transfer_rate
+}
+
+plot {
+title %g Web Server HTTP Error Rate
+source orcallator
+data htErr/s
+line_type area
+legend HTTP errors/s
+y_legend Errors/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#web_server_error_rate
+}
+
+# Interface bits per second for 10 Mbit interfaces.
+plot {
+title %g Interface Bits Per Second: $1
+source orcallator
+data 1024 * 8 * ((?:(?:elxl)|(?:le)|(?:qe))\d+)InKB/s
+data 1024 * 8 * $1OuKB/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Bits/s
+data_min 0
+data_max 10000000
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_bits_per_second
+}
+
+# Interface bits per second for 100 Mbit interfaces.
+plot {
+title %g Interface Bits Per Second: $1
+source orcallator
+data 1024 * 8 * ((?:(?:be)|(?:dmfe)|(?:eri)|(?:hme)|(?:qfe)|(?:znb))\d+)InKB/s
+data 1024 * 8 * $1OuKB/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Bits/s
+data_min 0
+data_max 100000000
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_bits_per_second
+}
+
+# Interface bits per second for 1 Gbit interfaces.
+plot {
+title %g Interface Bits Per Second: $1
+source orcallator
+data 1024 * 8 * ((?:(?:ce)|(?:v?ge)|(?:skge))\d+)InKB/s
+data 1024 * 8 * $1OuKB/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Bits/s
+data_min 0
+data_max 1000000000
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_bits_per_second
+}
+
+plot {
+title %g Interface Packets Per Second: $1
+source orcallator
+data (.*\d+)Ipkt/s
+data $1Opkt/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Packets/s
+data_min 0
+data_max 100000
+flush_regexps 1
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_packets_per_second
+}
+
+plot {
+title %g Interface Errors Per Second: $1
+source orcallator
+data (.*\d+)IErr/s
+data $1OErr/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Errors/s
+data_min 0
+flush_regexps 1
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_errors_per_second
+}
+
+plot {
+title %g Interface Deferred Packet Rate
+source orcallator
+data (.*\d+)Defr/s
+line_type area
+legend $1
+y_legend Defers/s
+data_min 0
+flush_regexps 1
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_deferred_packet_rate
+}
+
+plot {
+title %g Interface Collisions
+source orcallator
+data (.*\d+)Coll%
+line_type area
+legend $1
+y_legend Percent
+data_min 0
+data_max 200
+flush_regexps 1
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_collisions
+}
+
+plot {
+title %g Interface Nocanput Rate
+source orcallator
+data (.*\d+)NoCP/s
+line_type area
+legend $1
+y_legend Nocanput/s
+data_min 0
+flush_regexps 1
+href http://www.orcaware.com/orca/docs/orcallator.html#interface_nocanput_rate
+}
+
+plot {
+title %g TCP Bits Per Second
+source orcallator
+data 1024 * 8 * tcp_InKB/s
+data 1024 * 8 * tcp_OuKB/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Bits/s
+data_min 0
+data_max 1000000000
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_bits_per_second
+}
+
+plot {
+title %g TCP Segments Per Second
+source orcallator
+data tcp_Iseg/s
+data tcp_Oseg/s
+line_type area
+line_type line1
+legend Input
+legend Output
+y_legend Segments/s
+data_min 0
+data_max 20000
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_segments_per_second
+}
+
+plot {
+title %g TCP Retransmission & Duplicate Received Percentage
+source orcallator
+data tcp_Ret%
+data tcp_Dup%
+line_type area
+line_type line1
+legend Retransmission
+legend Duplicate received
+y_legend Percent
+data_min 0
+data_max 200
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_retransmission_duplicate_received_percentage
+}
+
+plot {
+title %g TCP New Connection Rate
+source orcallator
+data tcp_Icn/s
+data tcp_Ocn/s
+line_type area
+line_type line1
+legend Input - passive
+legend Output - active
+y_legend New Connections/s
+data_min 0
+data_max 10000
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_new_connection_rate
+}
+
+plot {
+title %g TCP Number Open Connections
+source orcallator
+data tcp_estb
+line_type area
+legend # open connections
+y_legend Number Open TCP Connections
+data_min 0
+data_max 50000
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_number_open_connections
+}
+
+plot {
+title %g TCP Reset Rate
+source orcallator
+data tcp_Rst/s
+line_type area
+legend Number TCP resets/s
+y_legend Resets/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_reset_rate
+}
+
+plot {
+title %g TCP Attempt Fail Rate
+source orcallator
+data tcp_Atf/s
+line_type area
+legend TCP attempt fails/s
+y_legend TCP Attempt Fails/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_attempt_fail_rate
+}
+
+plot {
+title %g TCP Listen Drop Rate
+source orcallator
+data tcp_Ldrp/s
+data tcp_LdQ0/s
+data tcp_HOdp/s
+legend TCP listen drops
+legend TCP listen drop Q0
+legend TCP half open drops
+y_legend TCP Listen Drops/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#TCP_listen_drop_rate
+}
+
+plot {
+title %g Sleeps on Mutex Rate
+source orcallator
+data smtx
+data smtx/cpu
+line_type area
+line_type line1
+legend Sleeps on mutex
+legend Sleeps on mutex/cpu
+y_legend Sleeps on Mutex/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#sleeps_mutex_rate
+}
+
+plot {
+title %g NFS Server Call Rate
+source orcallator
+data nfss_calls
+data v2reads
+data v2writes
+data v3reads
+data v3writes
+data nfss_bad
+data_type counter
+line_type area
+line_type area
+line_type stack
+line_type stack
+line_type stack
+line_type stack
+legend NFS server calls/s
+y_legend NFS Server Calls/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#NFS_server_call_rate
+}
+
+plot {
+title %g NFS Server Call Distribution
+source orcallator
+data v2reads
+data v2writes
+data v3reads
+data v3writes
+data_type counter
+line_type area
+line_type stack
+line_type stack
+line_type stack
+line_type stack
+y_legend NFS Server Calls/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#NFS_server_call_distribution
+}
+
+plot {
+title %g NFS Client Call Rate
+source orcallator
+data nfs_call/s
+line_type area
+legend NFS client calls/s
+y_legend NFS Client Calls/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#NFS_client_call_rate
+}
+
+plot {
+title %g NFS Timeouts & Bad Transmits Rate
+source orcallator
+data nfs_timo/s
+data nfs_badx/s
+line_type area
+line_type line1
+legend NFS timeouts
+legend Bad transmits
+y_legend Count/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#NFS_timeouts_bad_transmits_rate
+}
+
+#plot {
+#title %g Disk Run Percent
+#source orcallator
+#data disk_runp_((?:c\d+t\d+d\d+)|(?:c\d+d\d+)|(?:[ms]d\d+))
+#line_type line2
+#legend $1
+#y_legend Run Percent
+#data_min 0
+#data_max 100
+#plot_min 0
+#href http://www.orcaware.com/orca/docs/orcallator.html#disk_run_percent
+#}
+
+plot {
+title %g Cache Hit Percentages
+source orcallator
+data dnlc_hit%
+data inod_hit%
+line_type area
+line_type line1
+legend DNLC
+legend Inode cache
+y_legend Percent
+data_min 0
+data_max 100
+href http://www.orcaware.com/orca/docs/orcallator.html#cache_hit_percentages
+}
+
+plot {
+title %g Cache Reference Rate
+source orcallator
+data dnlc_ref/s
+data inod_ref/s
+line_type area
+line_type line1
+legend DNLC
+legend Inode cache
+y_legend References/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#cache_reference_rate
+}
+
+plot {
+title %g Cache Inode Steal Rate
+source orcallator
+data inod_stl/s
+line_type area
+legend Inode w/page steals/s
+y_legend Steals/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#inode_steal_rate
+}
+
+
+plot {
+title %g Memory Page Scan Rate
+source orcallator
+data scanrate
+line_type area
+legend Page scan rate
+y_legend Pages/s
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#page_scan_rate
+}
+
+plot {
+title %g Memory Page Residence Time
+source orcallator
+data page_rstim
+line_type area
+legend Page residence time
+y_legend Seconds
+data_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#page_residence_time
+}
+
+plot {
+title %g Memory Pages Locked & IO
+source orcallator
+data pageslock
+data pagesio
+line_type area
+line_type line1
+legend Locked
+legend IO
+y_legend Number Of Pages
+data_min 0
+plot_min 0
+href http://www.orcaware.com/orca/docs/orcallator.html#pages_locked_IO
+}
+
Added: trunk/orca/data_gatherers/hp/orca-hp-stat.pl
==============================================================================
--- (empty file)
+++ trunk/orca/data_gatherers/hp/orca-hp-stat.pl Sat Apr 3 16:07:15 2004
@@ -0,0 +1,442 @@
+#!/usr/contrib/bin/perl
+#
+# Version 1.5
+
+# Description:
+# Collect general perfromance statistics formatted for
+# interpretaion by Orca.
+
+# Usage:
+# The following variables may be set:
+#
+# OUT_ROOT root directory for datafiles (eg /opt/log/performance)
+# INTERVAL the number of seconds between checks (eg 300 = 5 min)
+# DURATION numer of hours to run (eg 1 = 1 hr)
+#
+# This script runs various standard system utilities to collect
+# system performance statistics and writes them out to datafile named
+# HOSTNAME/stats.YYYY-MM-DD-HHmm under the OUT_ROOT directory.
+#
+# It runs for the the numbers specified by DURATION collecting data
+# every INTERVAL number of seconds. After DURATION, the script
+# closes and compresses it's datafile via /usr/bin/compress and then
+# exits. If DURATION=24 and INTERVAL=300 (recommended) then the
+# following cron entry would collect continuos stats for a system:
+#
+# 0 0 * * * /<PATH_TO_SCRIPT>/orca-hp-stat.pl
+#
+# 2003-09-10 - RV - Modifies for HP ... Rajesh Verma(rajeshverma at aixdude.com)
+# ver 1.0
+# 2001-04-16 - JDK - Genesis... by Jason D. Kelleher
+# 2001-05-02 - JDK - Updates to make data aggregation easier.
+# Added #open connections, pagestotl.
+# 2001-07-06 - JDK - added command-line args & data checks
+# 2001-07-09 - JDK - added signal handler, column checks, & umask
+# 2001-07-10 - JDK - now autodetects interfaces via netstat -i
+# v1.5
+#
+# $HeadURL$
+# $LastChangedDate$
+# $LastChangedBy$
+# $LastChangedRevision$
+
+# Note: Execution speed is more important than cleanliness here.
+#
+#
+# There are some script which are used for gettting data and there are
+#
+# phymem -- for getting physical memory
+# Copy this script in the path /usr/local/bin
+#
+##################BEGIN OF FILE##################
+#/* Programma to determine statistics about the physical and virtual
+# memory of a HP workstation, independant of HP-UX version.
+#Shows some of the fields on std out.
+#
+#Program: phymem
+#Author: Eef Hartman
+#Version: 1.1
+#Last change: 97/01/06
+#Compiled: 97/10/17 09:17:31
+#
+#Based on code, posted in the HPadmin mailing list.
+#
+#To compile: cc -o phys_mem phys_mem.c
+#
+ #*/
+#
+#static char SCCSid[] = "@(#)phys_mem 1.1";
+#
+##include <sys/pstat.h>
+#
+#void main() {
+#struct pst_static stat_buf;
+#struct pst_dynamic dyn_buf;
+#
+#pstat(PSTAT_STATIC,&stat_buf,sizeof(stat_buf),0,0);
+#pstat(PSTAT_DYNAMIC,&dyn_buf,sizeof(dyn_buf),0,0);
+#
+#printf("Physical %ld \n",(stat_buf.physical_memory/256)*1000);
+#
+#return; }
+#
+############END OF FILE#################
+#Other script is to get the df output correctly.
+#File Name : hpdf PATH: /usr/local/bin
+#
+###########SOF##############
+#Thanks to Mark.Deiss at acs-gsg.com, bdf output on HP-UX may appear on 2 lines
+#bdf -l | sed -e '/^[^ ][^ ]*$/{
+#N
+#s/[ ]*\n[ ]*/ /
+#}'
+#####################EOF#####################
+#
+#
+#
+# Explicitly set PATH to prevent odd problems if run manually.
+$ENV{PATH} = '/usr/bin:/etc:/usr/sbin:/usr/ucb:/sbin';
+
+$Usage_Message = '
+Usage: orca-hp-stat.pl [-r out_root] [-i interval] [-d duration] [-h]
+
+-r out_root set root output directory, default: /opt/log/performance
+-i interval number of seconds between checks, default: 300
+-d duration number of hours to run, default: 24
+-h this message
+
+';
+
+# Parse the command line arguments
+while ( $#ARGV >= 0 ) {
+
+ if ( $ARGV[0] eq "-r" ) {
+ shift @ARGV;
+ $OUT_ROOT = shift @ARGV;
+ }
+ elsif ( $ARGV[0] eq "-i" ) {
+ shift @ARGV;
+ $INTERVAL = shift @ARGV;
+ }
+ elsif ( $ARGV[0] eq "-d" ) {
+ shift @ARGV;
+ $DURATION = shift @ARGV;
+ }
+ elsif ( $ARGV[0] eq "-h" ) {
+ print $Usage_Message;
+ exit 0;
+ }
+ elsif ( $ARGV[0] =~ /^-/ ) {
+ die "Invalid flag: $ARGV[0]\n$Usage_Message";
+ }
+ else {
+ die "Invalid argument: $ARGV[0]\n$Usage_Message";
+ }
+}
+
+## BEGIN set defaults
+
+$OUT_ROOT ||= '/home/orca/orcallator'; # root directory for datafiles
+$INTERVAL ||= 300; # seconds between checks
+$DURATION ||= 24; # number of hours to run
+
+## END set defaults
+
+## Derived variables.
+$iterations = $DURATION * 60 * 60 / $INTERVAL; # Number of checks.
+chomp( $HOST = `uname -n` );
+$out_dir = "${OUT_ROOT}/${HOST}";
+( $sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst ) =
+ localtime(time);
+$stat_file =
+ sprintf( "%s/percol-%.2d-%.2d-%.2d-%1d%.2d", $out_dir, $year + 1900, $mon + 1,
+ $mday, $hour, $min );
+
+# Base all timestamps on start time.
+$start_time = time();
+$timestamp = 0;
+
+## Autodetect network interfaces
+#open IN, "ifconfig -a|";
+open IN, "netstat -i|";
+while (<IN>) {
+
+ # if ( /^(\S+):/ ) {
+ if (/^(\w+).*link/) {
+ push @net_interfaces, $1;
+ }
+}
+close IN;
+
+# Grab some base system info prior to collecting stats.
+open IN, "/usr/local/bin/phymem|";
+while (<IN>) {
+ if (/Physical (\d+) /) {
+ $pagestotl =
+ $1 * 1024 / 4096; # Grab realmem in KB and convert to pages.
+
+ ## this gets used down in the vmstat section
+ }
+}
+close IN;
+
+## Make sure we can write output.
+umask 0022; # make sure the file can be harvested
+unless ( -d $out_dir ) {
+ system( "mkdir", "-p", "$out_dir" );
+}
+open OUT, ">$stat_file" or die "ERROR: Could not open $stat_file: $!";
+my $oldfh = select OUT;
+$| = 1;
+select $oldfh;
+
+# Set signal handlers to close and compress the output
+# file just in case.
+$SIG{HUP} = \&exit_nicely;
+$SIG{INT} = \&exit_nicely;
+$SIG{QUIT} = \&exit_nicely;
+$SIG{TERM} = \&exit_nicely;
+
+# Set gloabals used for printing (or not) headers.
+$need_header = 1;
+$prev_header_cnt = 0;
+$prev_info_cnt = 0;
+
+while ( $iterations-- > 0 ) {
+
+ $timestamp = $timestamp ? time() : $start_time;
+ ( $sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst ) =
+ localtime(time);
+ $locltime = sprintf( "%.2d:%.2d:%.2d", $hour, $min, $sec );
+
+ ## Get runq data
+ open IN, "uptime |";
+ while (<IN>) {
+ if (/load average:\s+(\S+),\s+(\S+),\s+(\S+)/) {
+ $load_info = join "\t", $1, $2, $3;
+ }
+ }
+ close IN;
+ $load_header = "1runq\t5runq\t15runq";
+
+ if ( scalar( split ' ', $load_header ) != scalar( split ' ', $load_info ) )
+ {
+ $load_header = '';
+ $load_info = '';
+ $need_header = 1;
+ print STDERR "WARNING: load header does not match load info.\n";
+ }
+
+ ## Get number of system processes
+ $num_proc = -1; # Don't count the header.
+ open IN, "ps -e |";
+ while (<IN>) {
+ $num_proc++;
+ }
+ close IN;
+ $proc_info = $num_proc;
+ $proc_header = '#proc';
+
+ if ( scalar( split ' ', $proc_header ) != scalar( split ' ', $proc_info ) )
+ {
+ $proc_header = '';
+ $proc_info = '';
+ $need_header = 1;
+ print STDERR "WARNING: #proc header does not match #proc info.\n";
+ }
+
+ ## Get vmstat data
+ open IN, "vmstat 1 2|";
+ while (<IN>) {
+ chomp;
+ if (/^[\s\d]+$/) {
+
+ # overwrite first line on 2nd pass
+ (
+ $vmstat_r, $vmstat_b, $vmstat_wa, $vmstat_avm, $vmstat_fre,
+ $vmstat_re, $vmstat_at, $vmstat_pi, $vmstat_po, $vmstat_fr,
+ $vmstat_cy, $vmstat_sr, $vmstat_inf, $vmstat_syf,
+ $vmstat_csf, $vmstat_us, $vmstat_sy, $vmstat_id
+ )
+ = split;
+ $vmstat_info = join "\t", $vmstat_avm, $vmstat_fre, $pagestotl,
+ $vmstat_pi, $vmstat_po, $vmstat_fr, $vmstat_sr, $vmstat_us,
+ $vmstat_sy, $vmstat_wa, $vmstat_id;
+ }
+ }
+ close IN;
+ $vmstat_header =
+"pagesactive\tpagesfree\tpagestotl\tPagesI/s\tPagesO/s\tPagesF/s\tscanrate\tusr%\tsys%\twio%\tidle%";
+
+ if ( scalar( split ' ', $vmstat_header ) !=
+ scalar( split ' ', $vmstat_info ) )
+ {
+ print STDERR "WARNING: vmstat header does not match vmstat info.\n";
+ $vmstat_header = '';
+ $vmstat_info = '';
+ $need_header = 1;
+ }
+
+ ## Get filesystem data
+ $fs_header = '';
+ $fs_info = '';
+ open IN, "/usr/local/bin/hpdf |";
+ while (<IN>) {
+ chomp;
+
+ if (m%^/%) {
+ ( $mnt_dev, $blocks, $used, $free, $pct_used, $iused, $ifree,
+ $ipct_used, $mnt ) = split;
+
+ # Recalculate percents because df rounds.
+ $fs_info .= "\t"
+ . sprintf( "%s\t%s\t%s\t%.5f\t%d\t%s\t%s\t%.5f", $blocks, $used,
+ $free, ( $used / $blocks ) * 100, ( $iused + $ifree ), $iused,
+ $ifree, ( $iused / ( $iused + $ifree ) ) * 100 );
+ $fs_header .= "\t" . join "\t", "mntC_$mnt", "mntU_$mnt",
+ "mntA_$mnt", "mntP_$mnt", "mntc_$mnt", "mntu_$mnt", "mnta_$mnt",
+ "mntp_$mnt";
+ }
+ }
+ close IN;
+
+ if ( scalar( split ' ', $fs_header ) != scalar( split ' ', $fs_info ) ) {
+ print STDERR
+ "WARNING: filesystem header does not match filesystem info.\n";
+ $fs_header = '';
+ $fs_info = '';
+ $need_header = 1;
+ }
+
+ ## Get iostat data
+ $disk_t = 0;
+ $disk_rK = 0;
+ $disk_wK = 0;
+ undef %disks;
+ open IN, "iostat 1 2|";
+
+ while (<IN>) {
+ if (/^(\S+)\s+\S+\s+\S+\s+(\S+)\s+(\d+)\s+(\d+)/) {
+ my $disk = $1;
+ my $tps = $2;
+ my $rK = $3;
+ my $wK = $4;
+ if ( not $disks{$disk} ) {
+ $disks{$disk}++; # Get rK & wK from first pass.
+ $disk_rK += $rK;
+ $disk_wK += $wK;
+ }
+ else {
+ $disk_t += $tps; # Get trans per sec from second pass.
+ }
+ }
+ }
+ close IN;
+ $iostat_header = "disk_t/s\tdisk_rK/s\tdisk_wK/s\t";
+ $iostat_info = "${disk_t}\t${disk_rK}\t${disk_wK}";
+
+ if ( scalar( split ' ', $iostat_header ) !=
+ scalar( split ' ', $iostat_info ) )
+ {
+ print STDERR "WARNING: iostat header does not match iostat info.\n";
+ $iostat_header = '';
+ $iostat_info = '';
+ $need_header = 1;
+ }
+
+ ## Get packet data
+ $packet_header = '';
+ $packet_info = '';
+
+ #foreach $interface ( split(/\s+/, $NET_INTERFACES) ) {
+ foreach $interface (@net_interfaces) {
+ $packet_header .=
+"${interface}Ipkt/s\t${interface}IErr/s\t${interface}Opkt/s\t${interface}OErr/s\t${interface}Coll/s\t";
+ open IN, "netstat -I $interface 1|";
+
+ while (<IN>) {
+ if (/^\s*(\d+)\s+(\d+)\s+(\d+)\s+(\d+)\s+(\d+)\s+/) {
+ $packet_info .= "\t" . join "\t", $1, $2, $3, $4, $5;
+ last;
+ }
+ }
+ close IN;
+ }
+
+ if ( scalar( split ' ', $packet_header ) !=
+ scalar( split ' ', $packet_info ) )
+ {
+ print STDERR "WARNING: packet header does not match packet info.\n";
+ $packet_header = '';
+ $packet_info = '';
+ $need_header = 1;
+ }
+
+ ## Get TCP Connection data
+ $tcp_estb = 0;
+ open IN, "netstat -a |";
+ while (<IN>) {
+ if (/^tcp.+ESTABLISHED$/) {
+ $tcp_estb++;
+ }
+ }
+ close IN;
+ $tcp_info = $tcp_estb;
+ $tcp_header = 'tcp_estb';
+
+ if ( scalar( split ' ', $tcp_estb_header ) !=
+ scalar( split ' ', $tcp_estb_info ) )
+ {
+ print STDERR "WARNING: tcp_estb header does not match tcp_estb info.\n";
+ $tcp_estb_header = '';
+ $tcp_estb_info = '';
+ $need_header = 1;
+ }
+
+ ## Join header and info then verify column counts.
+ $out_header = join "\t", "timestamp", "locltime", $load_header,
+ $proc_header, $vmstat_header, $fs_header, $iostat_header, $packet_header,
+ $tcp_header;
+ $out_header =~ tr/ \t/\t/s; # translate whitespace to single tabs
+
+ $out_info = join "\t", $timestamp, $locltime, $load_info, $proc_info,
+ $vmstat_info, $fs_info, $iostat_info, $packet_info, $tcp_info;
+ $out_info =~ tr/ \t/\t/s; # translate whitespace to single tabs
+
+ $header_cnt = split ' ', $out_header;
+ $info_cnt = split ' ', $out_info;
+ if ( $header_cnt != $info_cnt ) {
+ print STDERR
+ "ERROR: header columns do not equal data columns. Exiting.\n";
+ &exit_nicely;
+ }
+ elsif ( $header_cnt != $prev_header_cnt or $info_cnt != $prev_info_cnt ) {
+ $need_header = 1;
+ }
+ $prev_header_cnt = $header_cnt;
+ $prev_info_cnt = $info_cnt;
+
+ ## Write output
+ if ($need_header) {
+ print OUT $out_header, "\n";
+ $need_header = 0;
+ }
+ print OUT $out_info, "\n";
+
+ sleep $INTERVAL - ( time() - $timestamp );
+
+}
+close OUT;
+
+ at args = ( "gzip", "-f", "$stat_file" );
+system(@args);
+
+exit 0;
+
+# This subroutine is called by the signal handler.
+sub exit_nicely {
+ close OUT;
+ @args = ( "gzip", "-f", "$stat_file" );
+ system(@args);
+ exit 0;
+}
More information about the Orca-checkins
mailing list