[check_postgres] Fix for the connection action
Guillaume Lelarge
guillaume at lelarge.info
Mon Oct 3 20:46:42 UTC 2011
On Sun, 2011-09-25 at 22:02 +0200, Guillaume Lelarge wrote:
> Hi,
>
> Right now, if we try to check the connection for two databases, if the
> second one doesn't work, check_postgres reports the error for the first
> one:
>
> $ LANG=C ./check_postgres.pl --action=connection -db postgres,template0
> FATAL: database "template0" is not currently accepting connections
> Use of uninitialized value in join or string at ./check_postgres.pl line
> 1610.
> POSTGRES_CONNECTION CRITICAL: DB "postgres" | time=0.01s
>
> So here is a fix that checks the connection for each database, and
> reports correctly success and failure.
>
> I will apply it in a few days if there is no objection.
>
Applied.
--
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com
More information about the Check_postgres
mailing list