~jontai/openvista-gtm-integration/bug672798

« back to all changes in this revision

Viewing changes to scripts/usr/share/munin/plugins/openvista_processes_

  • Committer: Jonathan Tai
  • Date: 2010-06-14 21:01:54 UTC
  • mfrom: (131.1.1 bug594343)
  • Revision ID: jon.tai@medsphere.com-20100614210154-k4fu8l85b3l5vgkt
Merge bug 594343 - OpenVista Processes munin plugin always shows 0 terminal and RPC broker connections

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
# OpenVista instance.
5
5
 
6
6
 
7
 
# Copyright (C) 2009 Medsphere Systems Corporation
 
7
# Copyright (C) 2009-2010 Medsphere Systems Corporation
8
8
#
9
9
# This program is free software; you can redistribute it and/or modify it solely
10
10
# under the terms of the GNU Affero General Public License version 3 as published
92
92
        cd "$root/$INSTANCE/tmp"
93
93
 
94
94
        ss=`mumps -run THIS^%SS | tail -n +7 | head -n -2`
95
 
        terminal=`echo "$ss" | grep -v '^$' | awk '{ print $2 }' | grep '/dev/pts' | wc -l`
96
 
        rpc=`echo "$ss" | grep -v '^$' | awk '{ print $2 }' | grep 'CONNECTED' | wc -l`
 
95
        terminal=`echo "$ss" | grep -v '^$' | awk '{ print $2 " " $3 }' | grep '/dev/pts' | wc -l`
 
96
        rpc=`echo "$ss" | grep -v '^$' | awk '{ print $2 " " $3 }' | grep 'CONNECTED' | wc -l`
97
97
        all=`echo "$ss" | grep -v '^$' | wc -l`
98
98
        other=`expr $all - $terminal - $rpc`
99
99
        echo "terminal.value $terminal"