diff options
author | Greg Sabino Mullane | 2010-12-28 22:07:32 +0000 |
---|---|---|
committer | Greg Sabino Mullane | 2010-12-28 22:07:32 +0000 |
commit | 02ec539a551ad439eeda2d6236bda634ba8b36b9 (patch) | |
tree | a5ba37820064cb11512452f4436b46dfa9218f9a | |
parent | c48414cab4baa473696d6b836cd201591d64760f (diff) |
More tweaks to bloat display.
-rwxr-xr-x | check_postgres.pl | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/check_postgres.pl b/check_postgres.pl index e38010174..17dea5efa 100755 --- a/check_postgres.pl +++ b/check_postgres.pl @@ -2844,21 +2844,21 @@ FROM ( for my $r (@{$db->{slurp}}) { - my ($dbname,$schema,$table,$tups,$pages,$otta,$bloat,$wp,$wb) = @$r{ - qw/ db schemaname tablename tups pages otta tbloat wastedpages wastedbytes/}; - my $ws = pretty_size($wb); - my ($index,$irows,$ipages,$iotta,$ibloat,$iwp,$iwb) = @$r{ - qw/ iname irows ipages iotta ibloat wastedipgaes wastedibytes/}; - my $iws = pretty_size($iwb); + for my $v (values %$r) { + $v =~ s/(\d+) bytes/pretty_size($1,1)/ge; + } + + my ($dbname,$schema,$table,$tups,$pages,$otta,$bloat,$wp,$wb,$ws) = @$r{ + qw/ db schemaname tablename tups pages otta tbloat wastedpages wastedbytes wastedsize/}; + next if skip_item($table, $schema); + my ($index,$irows,$ipages,$iotta,$ibloat,$iwp,$iwb,$iws) = @$r{ + qw/ iname irows ipages iotta ibloat wastedipgaes wastedibytes wastedisize/}; + ## Made it past the exclusions $max = -2 if $max == -1; - for my $v (values %$r) { - $v =~ s/\| (\d+) bytes/'| ' . pretty_size($1,1)/ge; - } - ## Do the table first if we haven't seen it if (! $seenit{"$dbname.$schema.$table"}++) { $db->{perf} = " $schema.$table=$wb"; @@ -8760,7 +8760,7 @@ Items not specifically attributed are by Greg Sabino Mullane. =over 4 -=item B<Version 2.15.2> +=item B<Version 2.15.2> December 28, 2010 Better formatting of sizes in the bloat action output. |