summaryrefslogtreecommitdiff
path: root/check_postgres.pl
diff options
context:
space:
mode:
authorRuslan Kabalin2011-03-14 22:18:36 +0000
committerGreg Sabino Mullane2011-03-14 22:18:36 +0000
commit9bf854279df25ec1edfc7f0b61bf5018a35f7cbe (patch)
tree09a1689bbb1040242af79f7b3750b684e63e447a /check_postgres.pl
parent32c35b3aa4df680223f6f75a3f869d0f36915bb8 (diff)
[backends] do not list excluded databases in output.
When used with --include or --exclude settings, listing all available databases in perfomance output might be confusing. Thus, only those databases that are taken into account for connectons number calculation are listed.
Diffstat (limited to 'check_postgres.pl')
-rwxr-xr-xcheck_postgres.pl4
1 files changed, 2 insertions, 2 deletions
diff --git a/check_postgres.pl b/check_postgres.pl
index 83f10abe0..6efa00356 100755
--- a/check_postgres.pl
+++ b/check_postgres.pl
@@ -2853,10 +2853,10 @@ ORDER BY datname
elsif ($w3) {
$nwarn = (int $w2*$limit/100)
}
- $db->{perf} .= sprintf ' %s=%s;%s;%s;0;%s',
- perfname($r->{datname}), $r->{current}, $nwarn, $ncrit, $limit;
if (! skip_item($r->{datname})) {
+ $db->{perf} .= sprintf ' %s=%s;%s;%s;0;%s',
+ perfname($r->{datname}), $r->{current}, $nwarn, $ncrit, $limit;
$total += $r->{current};
}
}