Re: PQping command line tool

From: Greg Stark <stark(at)mit(dot)edu>
To: Greg Sabino Mullane <greg(at)turnstep(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: PQping command line tool
Date: 2012-10-10 17:17:25
Message-ID: CAM-w4HOx1vzUwRoyvsg5fwuTO68ViiTVVfpzkoUe2Cs3SJZtYg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Oct 10, 2012 at 6:11 PM, Greg Sabino Mullane <greg(at)turnstep(dot)com> wrote:
> Jim Nasby pointed out:
>
>> It'd be useful to us to have a utility that could cleanly validate
>> the server was up and communicating, without having to actually login.
>
> Well sure, but wouldn't it be even more useful to validate at the
> same time that logins are working? :)

Not necessarily. To test if logins are working your tool needs access
to the credentials of a user you want to test. That makes the tool
less useful to someone who wants to run it on a machine or from a
process that shouldn't have access to those credentials.

Of course it's not a problem to have it as an option. But I'm just
agreeing with Jim that it can be useful to have a tool that is capable
of doing less.

Fwiw the current architecture of the postmaster is designed to *not*
start up a backend until after the the initial exchange is done. That
protects against denial of service attacks that open lots of TCP
connections without having any credentials. But it means that just
making a TCP connection is verifying less of the system.

--
greg

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Daniel Frey 2012-10-10 17:32:16 Bug / feature request for floating point to string conversion
Previous Message Greg Sabino Mullane 2012-10-10 17:11:52 Re: PQping command line tool