Re: TCPIP connection on local host using md5

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jimy McDermott <jmcdermott(at)catbird(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: TCPIP connection on local host using md5
Date: 2012-10-14 20:15:13
Message-ID: 2603.1350245713@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Jimy McDermott <jmcdermott(at)catbird(dot)com> writes:
> pg_hba.conf:
> # TYPE DATABASE USER ADDRESS METHOD

> # "local" is for Unix domain socket connections only
> local all all peer
> # IPv4 local connections:
> host all all 127.0.0.1/32 ident
> # IPv6 local connections:
> host all all ::1/128 ident
> # Allow replication connections from localhost, by a user with the
> # replication privilege.
> host all all 192.168.20.250/32 md5 #
> This line supports the remote connection that works great
> host all report 127.0.0.1/32 md5 #
> This line is intended to support the local connection that is failing

pg_hba.conf lines are considered in order, so the second one (with the
ident auth method) is matching the incoming connection before the last
one ever gets considered. You need to re-order those lines. The rule
of thumb is "most specific rule first".

regards, tom lane

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Tore Halset 2012-10-14 21:48:55 autovacuum with lots of open file references to deleted files
Previous Message Vincent 2012-10-14 08:10:29 Re: Query with limit takes hours