-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
InformixDB: Onstat support for couple of item and Minor refactoring (#31
) * InformixDB: Onstat support for couple of item and Minor refactoring * InformixDB: Minor refactoring
- Loading branch information
1 parent
9a0aa6b
commit ab6c126
Showing
8 changed files
with
104 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
# (c) Copyright IBM Corp. 2024 | ||
# (c) Copyright Instana Inc. | ||
|
||
result=$(cd $1 && | ||
export INFORMIXDIR=$2 && | ||
export ONCONFIG=$3 && | ||
export INFO RMIXSERVER=$4 && | ||
export PATH=$INFORMIXDIR/bin:$PATH && | ||
export INFORMIXSQLHOSTS=$INFORMIXDIR/etc/$5 && | ||
./onstat -g ses active | awk 'BEGIN {RS=""; FS="\n"} NR==2 {linecount = NF -2; if (linecount>0) print linecount; else print 0}') | ||
|
||
echo $result |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
# (c) Copyright IBM Corp. 2024 | ||
# (c) Copyright Instana Inc. | ||
|
||
result=$(cd $1 && | ||
export INFORMIXDIR=$2 && | ||
export ONCONFIG=$3 && | ||
export INFO RMIXSERVER=$4 && | ||
export PATH=$INFORMIXDIR/bin:$PATH && | ||
export INFORMIXSQLHOSTS=$INFORMIXDIR/etc/$5 && | ||
./onstat -g wai | awk 'BEGIN {RS=""; FS="\n"} NR==2 {linecount = NF -2; if (linecount>0) print linecount; else print 0}') | ||
|
||
echo $result |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.