From: | Chris Miller <cjm(at)tryx(dot)org> |
---|---|
To: | pgsql-general <pgsql-general(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Test mail for pgsql-general |
Date: | 2024-09-10 23:21:10 |
Message-ID: | 1738731565.8400.1726010470879.JavaMail.zimbra@tryx.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hi Folks,
I am confused about authentication. I understand that in the local connection case, I have choices of “peer”, and “md5” (password).
In pg_hba.conf, I have the lines:
local all all peer
local all all md5
I have an OS user “postgres”, and I can “su – postgres”, which brings me to a shell and I can invoke psql successfully.
I believe that, as root, I should be able to “psql -U postgres -W” and logon with a password. I can’t. When I try, I get:
psql: error: connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: Peer authentication failed for user "postgres"
Notice I am failing “peer” authentication. Seems to me that if I explicitly ask for a password, “-W”, I should be using “md5” authentication.
Can anybody straighten me out?
Thanks for the help,
--
Chris.
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2024-09-10 23:26:19 | Re: Test mail for pgsql-general |
Previous Message | Christophe Pettus | 2024-09-10 23:05:54 | Re: Overlapping values (?) in multi-column partitioned tables |