We use check_postgres to monitor our PostgreSQL servers.
Sometimes there are peaks in the number of locks and the check alerts.
Up to now the check only tells us the number of locks. This does not help in debugging where the locks come from.
I would like to see additional output. For example this output:
select * from pg_stat_activity order by datname
The output of the above statement is long and AFAIK check scripts must only output one line.
How to output additional information if nagios/icinga check fails?