Module: check_mk
Branch: master
Commit: 28cb7d271468e1eb15f713a3096feabe79349609
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=28cb7d271468e1…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue May 14 12:44:33 2013 +0200
mk_postgres plugin: replace select * with list of explicit columns (fix for PG 9.1)
---
ChangeLog | 1 +
agents/plugins/mk_postgres | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/ChangeLog b/ChangeLog
index 15a2ce5..f4bc640 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -94,6 +94,7 @@
router mode, serialnumber and temperature sensors
* uptime, snmp_uptime, esx_vsphere_counters.uptime: allow to set lower and upper
levels
* winperf_processor: Now displays (and scales) to number of cpus in pnpgraph
+ * mk_postgres plugin: replace select * with list of explicit columns (fix for PG
9.1)
Notifications:
* notify.py: unique spoolfiles name no longer created with uuid
diff --git a/agents/plugins/mk_postgres b/agents/plugins/mk_postgres
index d98e431..a041a9c 100755
--- a/agents/plugins/mk_postgres
+++ b/agents/plugins/mk_postgres
@@ -13,5 +13,5 @@ echo '<<<postgres_sessions>>>'
echo "select current_query = '<IDLE>', count(*) from pg_stat_activity
group by (current_query = '<IDLE>');" | su - $USER -c "psql -d
postgres -A -t -F' '"
echo '<<<postgres_stat_database:sep(59)>>>'
-echo 'select *, pg_database_size(datname) as "datsize" from
pg_stat_database;' \
+echo 'select datid, datname, numbackends, xact_commit, xact_rollback, blks_read,
blks_hit, tup_returned, tup_fetched, tup_inserted, tup_updated, tup_deleted, conflicts,
pg_database_size(datname) "datsize" from pg_stat_database;' \
| su - $USER -c "psql -d postgres -A -F';'" | sed '$d'