On 12/02/11 3:13 PM, Andre Lopes wrote:
> [code]
> Exception Value:
> FATAL: Ident authentication failed for user "mypoatgreuser"
> [/code]
>
> There is more permissions that I must to give to the user
> "mypoatgreuser"? What could be wrong here?
'ident' is the default authentication type for local domain socket
connections, and it means that user 'x' can only connect as postgresql
role 'x'.
A web app likely runs as httpd or webuser or some such, so ident
authentication isn't really applicable.
You control the authentication methods in the pg_hba.conf file. I'd
suggest doing this...
1) set (and remember) passwords for all roles, including the "postgres"
default adminstrator role....
ALTER ROLE postgres WITH PASSWORD 'somepassword';
2) configure pg_hba.conf as follows...
local all postgres ident
local all all md5
host all all 127.0.0.1/32 md5
host all all (yoursubnet) md5
and HUP the master postgres process (pg_ctl ... reload).
this way, the postgres user can authenticate locally with ident, but all
other users will require passwords.
--
john r pierce N 37, W 122
santa cruz ca mid-left coast