IPV6 issue

Поиск
Список
Период
Сортировка
От Atul Kumar
Тема IPV6 issue
Дата
Msg-id CA+ONtZ62uKURz1SLZqhJ1pwwFJB0BRXzPRN1zdAX3xo0Vo-JFQ@mail.gmail.com
обсуждение исходный текст
Ответы Re: IPV6 issue
Re: IPV6 issue
Список pgsql-general
I have postgres 12 running in centos 7 on my two machines, recently I changed the authentication of entries of pg_hba.conf to scram-sha-256 for localhost.

Since then in my one machine, I have started getting the below error when I use command "psql postgres"

no pg_hba.conf entry for host "::1", user "postgres", database "postgres


I found that localhost is resolve to IPV6 by using below command:

getent hosts localhost

::1             localhost localhost.localdomain localhost6 localhost6.localdomain6


Then I tested the same issue in my second machine

getent hosts localhost

::1             localhost localhost.localdomain localhost6 localhost6.localdomain6


but in my second machine I didn't face any such issue while using command "psql postgres", I was able to login into the database without such error.


The pg_hba.conf on both machines are identical without having any IPV6 entry in it.


The entry of pg_hba.conf is like below:

# TYPE  DATABASE        USER            ADDRESS                 METHOD

 

# "local" is for Unix domain socket connections only

local   all           all                                          scram-sha-256

# IPv4 local connections:

host    all           postgres     127.0.0.1/32               scram-sha-256


I am not able to understand that my both machines are resolved to IPV6 then why is my first machine is throwing this error ?


Please help.




Regards.

В списке pgsql-general по дате отправления:

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: Odd Shortcut behaviour in PG14
Следующее
От: Ron Johnson
Дата:
Сообщение: Re: Odd Shortcut behaviour in PG14