Re: -d option for pg_isready is broken

From: Fabrízio de Royes Mello <fabriziomello(at)gmail(dot)com>
To: Josh Berkus <josh(at)agliodbs(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: -d option for pg_isready is broken
Date: 2013-11-16 02:01:23
Message-ID: CAFcNs+rSmgV389Eo7kSUiNrTKet4cpc=aoSXgXGXm4-Q5OoR8A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Nov 13, 2013 at 9:37 PM, Josh Berkus <josh(at)agliodbs(dot)com> wrote:

>
> handyrep(at)john:~/handyrep$ pg_isready --version
> pg_isready (PostgreSQL) 9.3.1
>
> handyrep(at)john:~/handyrep$ pg_isready -h john -p 5432 -U postgres -d
> postgres -q
> pg_isready: missing "=" after "postgres" in connection info string
>
> handyrep(at)john:~/handyrep$ pg_isready --host=john --port=5432
> --user=postgres --dbname=postgres
> pg_isready: missing "=" after "postgres" in connection info string
>
> handyrep(at)john:~/handyrep$ pg_isready -h john -p 5432 -U postgres
> john:5432 - accepting connections
>
> so apparently the -d option:
>
> a) doesn't work, and
> b) doesn't do anything
>
> I suggest simply removing it from the utility.
>
> I'll note that the -U option doesn't appear to do anything relevant
> either, but at least it doesn't error unnecessarily:
>
> handyrep(at)john:~/handyrep$ pg_isready -h john -p 5432 -U no_such_user
> john:5432 - accepting connections
>
>
The attached patch fix it.

Regards,

--
Fabrízio de Royes Mello
Consultoria/Coaching PostgreSQL
>> Timbira: http://www.timbira.com.br
>> Blog sobre TI: http://fabriziomello.blogspot.com
>> Perfil Linkedin: http://br.linkedin.com/in/fabriziomello
>> Twitter: http://twitter.com/fabriziomello

Attachment Content-Type Size
fix-pg-isready.patch text/x-diff 432 bytes

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2013-11-16 02:07:58 Re: pre-commit triggers
Previous Message Nigel Heron 2013-11-16 01:37:23 Re: review: autovacuum_work_mem