Re: IPV6 issue

Поиск
Список
Период
Сортировка
От Atul Kumar
Тема Re: IPV6 issue
Дата
Msg-id CA+ONtZ7rWWSzk3LEXiNEgMaqo048PjdPe03QjHForzD=+R5rng@mail.gmail.com
обсуждение исходный текст
Ответ на Re: IPV6 issue  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: IPV6 issue
Список pgsql-general
Hi,

unix_socket_directories is set to default i.e. /tmp and I could see the socket in /tmp directory.


Regards.




On Tue, Nov 28, 2023 at 2:11 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
Adrian Klaver <adrian.klaver@aklaver.com> writes:
> On 11/27/23 12:11, Atul Kumar wrote:
>> I found that localhost was set to .bash_profile and when I removed it
>> and then re-attempted to connected the database using "psql postgres", I
>> got this new error:
>>
>> psql postgres -p 5432
>> psql: error: could not connect to server: No such file or directory
>>         Is the server running locally and accepting
>>         connections on Unix domain socket
>> "/var/run/postgresql/.s.PGSQL.5432"?

> Do you have more then one version of psql installed?

Yeah, that.  You're apparently using a version of psql/libpq that
thinks the default Unix socket location is /var/run/postgresql;
but the postmaster you are using did not create a socket there.
(Probably it put one in /tmp instead, which is the out-of-the-box
default location.  But some distros consider that insecure so they
override it, typically to /var/run/postgresql/.)

The easiest workaround if you have a mishmash of Postgres libraries
is to tell the postmaster to create sockets in both places.
See "unix_socket_directories" parameter.

                        regards, tom lane

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

Предыдущее
От: Atul Kumar
Дата:
Сообщение: Re: IPV6 issue
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: IPV6 issue