Re: [GENERAL] Unable to connect to Postgresql

Поиск
Список
Период
Сортировка
От Joe Conway
Тема Re: [GENERAL] Unable to connect to Postgresql
Дата
Msg-id 9070bafa-3988-027f-e9e4-1d8df56a1a96@joeconway.com
обсуждение исходный текст
Ответ на Re: [GENERAL] Unable to connect to Postgresql  (John Iliffe <john.iliffe@iliffe.ca>)
Ответы Re: [GENERAL] Unable to connect to Postgresql  (John Iliffe <john.iliffe@iliffe.ca>)
Список pgsql-general
On 04/08/2017 01:23 PM, John Iliffe wrote:
> On Saturday 08 April 2017 09:38:07 Adrian Klaver wrote:
>> So what if you change the connection to use -h localhost?
>
> Can you please expand on that request?  I'm not sure where you want me to
> put that directive.  I'm using the mod_php module in Apache.

See the second example here:

http://php.net/manual/en/function.pg-connect.php

8<-------------
$dbconn2 = pg_connect("host=localhost port=5432 dbname=mary");
// connect to a database named "mary" on "localhost" at port "5432"
8<-------------

That will try to use a tcp connection on localhost instead of a unix socket.

Another question I don't believe has been asked is, what does your
pg_hba.conf look like?

Joe

--
Crunchy Data - http://crunchydata.com
PostgreSQL Support for Secure Enterprises
Consulting, Training, & Open Source Development


Вложения

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

Предыдущее
От: John Iliffe
Дата:
Сообщение: Re: [GENERAL] Unable to connect to Postgresql
Следующее
От: "Steve Petrie, P.Eng."
Дата:
Сообщение: [GENERAL] TimeScaleDB -- Open Source Time Series Database Released (www.i-programmer.info);