Re: Newbie's question: How can I connect to my postgresql-server?

From: Sam Mason <sam(at)samason(dot)me(dot)uk>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Newbie's question: How can I connect to my postgresql-server?
Date: 2009-09-24 19:59:44
Message-ID: 20090924195944.GH22438@samason.me.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

On Fri, Sep 25, 2009 at 02:47:23AM +0700, Ricky Tompu Breaky wrote:
> I'm sure that I used the correct password as "createuser" the
> account of 'ricky'.

By default; PG is set up not to use passwords in the "local" case. This
is what the "ident" in the error is about. Your PG username needs to be
the same as your Unix username or ident authentication will fail.

Have a look at:

http://www.postgresql.org/docs/current/interactive/auth-pg-hba-conf.html

if you want to change it to use passwords as the authentication method
in the local case.

Note, that you don't need to restart PG when adding/removing users,
but you do when changing the config files like pg_hba.conf and
postgresql.conf. It's a "inside"/"outside" PG thing, users are stored
in the database and hence PG knows when they're added/removed, but the
config files are outside and PG doesn't know when to go looking for
changes. There are plans to change this for pg_hba.conf, but you'll
have to wait a bit before that happens.

--
Sam http://samason.me.uk/

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Jerry LeVan 2009-09-24 20:16:46 Re: Log File Melancholy
Previous Message Sam Mason 2009-09-24 19:51:40 libpq port number handling

Browse pgsql-hackers by date

  From Date Subject
Next Message Euler Taveira de Oliveira 2009-09-24 20:51:09 plpgsql function is so slow
Previous Message Sam Mason 2009-09-24 19:51:40 libpq port number handling