Re: [ADMIN] Change Unix Socket directory at build time

Поиск
Список
Период
Сортировка
От Santiago DIEZ
Тема Re: [ADMIN] Change Unix Socket directory at build time
Дата
Msg-id CAJh8RqVOyPfujFJu6S1rvqjbp5un91fdw78DMJX49crguTNV6A@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [ADMIN] Change Unix Socket directory at build time  (Santiago DIEZ <santiago.diez@caoba.fr>)
Ответы Re: [ADMIN] Change Unix Socket directory at build time  ("David G. Johnston" <david.g.johnston@gmail.com>)
Список pgsql-admin
To be fully transparent, the issue I'm dealing with is the following:
If I set a specific unix_socket_directory in postgresql.conf then running
pg_ctl start -w -t5 -D '/val/lib/postgresql/9.4/main'
fails because I believe it cannot verify the server is running because
it's looking for socket in /tmp.
The command fails but the server is started and running.
I don't know if it makes any sense.

On a larger scale I only hope to solve part of the problem because if
I don't configure unix_socket_directory, then pg_ctl will wait for the
creation of a socket in /var/run/postgresql and will believe the
server is not started although it is.

So a more general question would be: "how to make sure pg_ctl expects
the socket in the right place whatever the config is?"

-------------------------
Santiago DIEZ
Quark Systems & CAOBA
23 rue du Buisson Saint-Louis, 75010 Paris
-------------------------


On Fri, Apr 14, 2017 at 6:33 PM, Santiago DIEZ <santiago.diez@caoba.fr> wrote:
> Fantastic, I have never dug into the .h files when building any
> program. That's quite new to me.
> Is the # character a comment or not? It seems like all line start with #define
>
> -------------------------
> Santiago DIEZ
> Quark Systems & CAOBA
> 23 rue du Buisson Saint-Louis, 75010 Paris
> -------------------------
>
> On Fri, Apr 14, 2017 at 6:21 PM, Andres Freund <andres@anarazel.de> wrote:
>>
>> Hi,
>>
>> On 2017-04-14 17:55:39 +0200, Santiago DIEZ wrote:
>> > I usualy change the unix_socket_directory in the server configuration but
>> > I'd like to change it for good at build time. I read everywhere (here
>> > <https://www.postgresql.org/docs/current/static/runtime-config-connection.html>
>> > for example):
>> > "unix_socket_directories (string)
>> > The default value is normally /tmp, but that can be changed at build time."
>> >
>> > Ok good but I've read ./configure --help and I cannot find how to do it.
>>
>> You need to edit src/include/pg_config_manual.h and adapat DEFAULT_PGSOCKET_DIR
>>
>> - Andres


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

Предыдущее
От: Santiago DIEZ
Дата:
Сообщение: Re: [ADMIN] Change Unix Socket directory at build time
Следующее
От: "David G. Johnston"
Дата:
Сообщение: Re: [ADMIN] Change Unix Socket directory at build time