Обсуждение: Postgres 9.4 and 9.5 on CentOS on same machine unix socket incompatibility

Поиск
Список
Период
Сортировка

Postgres 9.4 and 9.5 on CentOS on same machine unix socket incompatibility

От
Strahinja Kustudić
Дата:
I had Postgres 9.4 installed on CentOS 5 which is listening on default port 5432 and everything worked fine when I wanted to connect using the unix socket. Then I installed Postgres 9.5 (just installed it) and now psql wants to connect to a different unix socket path:

/usr/pgsql-9.4/bin/psql -U postgres
psql: 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"?


The thing is that 9.4 doesn't create a unix socket in that directory, it only creates it in /tmp. I think the problem is with all older versions, not just 9.4.

How does 9.5 tell all other psql versions where to search for the unix socket?


Strahinja Kustudić
| Lead System Engineer | Nordeus