Re: simple md5 authentication problems

Поиск
Список
Период
Сортировка
От chris smith
Тема Re: simple md5 authentication problems
Дата
Msg-id 3c1395330605051557v707f8b67xc87c06f3d379c956@mail.gmail.com
обсуждение исходный текст
Ответ на simple md5 authentication problems  ("robert" <robertlazarski@gmail.com>)
Ответы Re: simple md5 authentication problems  ("robert" <robertlazarski@gmail.com>)
Список pgsql-general
On 5 May 2006 02:22:32 -0700, robert <robertlazarski@gmail.com> wrote:
> Hi all, hope this is the right list.
>
> I have postgres 8.1 running on linux. We have tests that mostly run on
> windows. I want to run these tests on linux.
>
> On these windows boxes, pg_hba.conf has just one line:
>
> host    all         all         127.0.0.1/32          md5
>
> They use 'postgres' as the user and password to connect to a db.
>
> I couldn't start postgres on linux with just that line, so on linux I
> have:
>
> # "local" is for Unix domain socket connections only
> local   all         all                               ident sameuser
> # IPv4 local connections:
> host    all         all         127.0.0.1/32          md5
> # IPv6 local connections:
> host    all         all         ::1/128               ident sameuser
>
> I created my db as:
> postgres=# CREATE DATABASE maragato_test OWNER postgres;
>
> I seem to have a user 'postgres' - I'm using the default.
>
> postgres=# SELECT * FROM "pg_user";
>  usename  | usesysid | usecreatedb | usesuper | usecatupd |  passwd  |
> valuntil | useconfig
> ----------+----------+-------------+----------+-----------+----------+----------+-----------
>  postgres |       10 | t           | t        | t         | ******** |
>         |
>
> However, I get this error:
>
> /home/postgres> psql -h localhost maragato_test postgres
> Password for user postgres:
> psql: FATAL:  autenticação do tipo password falhou para usuário
> "postgres"
>
> Sorry - couldn't get local en_US working. That translates to:
> Authentication of type password failed for user postgres. I think that
> means 'ident password' . I tried to connect with java and I get the
> same error.
>
> I just need to connect to db 'maragato_test' on local host using
> 'postgres´ as the user and password, using md5.

Try '-h 127.0.0.1' rather than 'localhost' - it's still seeing the
connection as coming through the socket, not through tcpip, so it's
matching the "ident" rule.

--
Postgresql & php tutorials
http://www.designmagick.com/

В списке pgsql-general по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Google Summer of Code: Full Disjunctions
Следующее
От: elein
Дата:
Сообщение: Re: Rules on Select