pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: "Lic. Guillermo González" <g.gonzalez@cybira.biz>
To: Sukhdeep Johar <sukhdeep@gmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: help with - psql: FATAL: Password authentication failed
Date: Tue, 28 Dec 2004 11:02:23 -0400
Message-ID: <41D1757F.8080808@cybira.biz> (raw)
In-Reply-To: <2ef564dc041228055320229353@mail.gmail.com>
References: <2ef564dc04122802535f2b22c@mail.gmail.com>
	<2ef564dc041228025440383142@mail.gmail.com>
	<41D15C8C.7080600@cybira.biz>
	<2ef564dc041228055320229353@mail.gmail.com>

Sukhdeep Johar wrote:
> can i set database specific access permission in pg_hba.conf ? 
> Can you give me some more details. 
> 
> My pg_hba.conf setting is : 
> local   all         all         trust
> host    all         all         127.0.0.1         255.255.255.255   crypt
> I disabled all other lines. 
> 
> I changed the second line to this :
> host    all         all    0.0.0.0      0.0.0.0  trust
> Now the psql command passes, but even after removing
> all access restrictions, pg_connct() is still failing.
> 
> Can you please give some pointers what is going wrong ? 
> 
> -Sukhdeep
> 
> 
> 
> On Tue, 28 Dec 2004 09:15:56 -0400, Lic. Guillermo González
> <g.gonzalez@cybira.biz> wrote:
> 
>>Sukhdeep Johar wrote:
>>
>>>I followed these steps to create a new user :
>>>1. createuser -P gforge
>>>2. createdb -U gforge -E UNICODE gforge
>>>3. createlang plpgsql gforge
>>>
>>>this gave no errors.
>>>But when I try to log in, I get the foll error
>>># psql -h localhost -U gforge gforge
>>>psql: FATAL:  Password authentication failed for user "gforge"
>>>
>>>Any comments, what may be going wrong ?
>>>--
>>>Neither success nor failure is ever final
>>>
>>>
>>
>>Did you check your pg_hba.conf for gforge database access permisions?
>>
>>
> 
> 
> 
Try this,

In your pg_hba.conf
local   all         all                                             md5
host    all         all         127.0.0.1         255.255.255.255   md5

then execute with postgres user to reload de pg_hba.conf changes:

pg_ctl reload

and to access your database:

psql gforge -U gforge -W

Obs.:
- refer to the psql man pages for more information about psql options.
- Note that in the psql command is not present the -h localhost option.

Regards,



view thread (10+ messages)  latest in thread

Message-ID: <41D1757F.8080808@cybira.biz>
Permalink:  ../41D1757F.8080808@cybira.biz/
Also on:    postgresql.org/message-id/41D1757F.8080808@cybira.biz

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: g.gonzalez@cybira.biz, sukhdeep@gmail.com
  Subject: Re: help with - psql: FATAL: Password authentication failed
  In-Reply-To: <41D1757F.8080808@cybira.biz>
  References: <2ef564dc04122802535f2b22c@mail.gmail.com> <2ef564dc041228025440383142@mail.gmail.com> <41D15C8C.7080600@cybira.biz> <2ef564dc041228055320229353@mail.gmail.com> <41D1757F.8080808@cybira.biz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox