Maxy <maxy0440yxam(at)yahoo(dot)it> writes:
> Good morning, i have a pg_hba.conf
> local all all md5
> host all all 127.0.0.1/32 md5
> if i do a
> psql -d mydb
> pg asks me the password but if i do
> psql -U postgresql -d mydb
> pg don't ask me the password.
Sounds to me like Postgres isn't actually using the pg_hba.conf file you
think it is. Try "show hba_file;" while connected to see which file
is really being used. Also, if you changed the file's contents, you might
have forgotten to restart or SIGHUP the postmaster to get it to notice
the change.
regards, tom lane