From 1499a6818c77ec968210b248e89811b693caf875 Mon Sep 17 00:00:00 2001 From: Greg Sabino Mullane Date: Mon, 20 Feb 2012 15:34:54 -0500 Subject: Better detection of stats_command_string being off. Start work to allow txn_idle on old systems. --- check_postgres.pl | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'check_postgres.pl') diff --git a/check_postgres.pl b/check_postgres.pl index 4fc3c0005..6f0b2c3d2 100755 --- a/check_postgres.pl +++ b/check_postgres.pl @@ -1729,7 +1729,6 @@ our %testaction = ( table_size => 'VERSION: 8.1', index_size => 'VERSION: 8.1', query_time => 'VERSION: 8.1', - txn_idle => 'VERSION: 8.3', txn_time => 'VERSION: 8.3', wal_files => 'VERSION: 8.1', archive_ready => 'VERSION: 8.1', @@ -7521,14 +7520,14 @@ sub check_txn_idle { ## We do a lot of filtering based on the current_query my $cq = $r->{current_query}; - ## Return unknown if we cannot see because we are a non-superuser? + ## Return unknown if we cannot see because we are a non-superuser if ($cq =~ /insufficient/o) { add_unknown msg('psa-nosuper'); return; } - ## Return unknown if stats_command_string / track_activities is off? - if ($cq =~ /disabled/o) { + ## Return unknown if stats_command_string / track_activities is off + if ($cq =~ /disabled/o or $cq =~ //) { add_unknown msg('psa-disabled'); return; } -- cgit v1.2.3