From: | "Daniel Verite" <daniel(at)manitou-mail(dot)org> |
---|---|
To: | "John Iliffe" <john(dot)iliffe(at)iliffe(dot)ca> |
Cc: | pgsql-general(at)postgresql(dot)org,"Adrian Klaver" <adrian(dot)klaver(at)aklaver(dot)com>,"Joe Conway" <mail(at)joeconway(dot)com> |
Subject: | Re: Unable to connect to Postgresql |
Date: | 2017-04-10 15:53:35 |
Message-ID: | 634d8235-907c-405b-9ee1-ffeaecad2583@manitou-mail.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
John Iliffe wrote:
> So, the problem is resolved, although I have no idea why it was necessary.
The key seems to be the PrivateTmp=true in the systemd service.
Apache is not chrooted as demonstrated upthread, but that
setting alone makes the normal, system-wide /tmp inaccessible
to its processes, including the postgres Unix domain socket opened
there.
I suspect that your attempt to set PrivateTmp=false as a test was
missed by systemd for some reason. You could probably insist
in that direction and eventually make it work, but I don't see
how it's better than the alternative /var/pgsql or localhost through TCP.
> Also, I now have several hundred programmes to update to add the host path
> and none of them will now be portable.
Given that you set two directories: /tmp and /var/pgsql,
I would think you can let the other apps use /tmp as before
and have only Apache use /var/pgsql ?
Best regards,
--
Daniel Vérité
PostgreSQL-powered mailer: http://www.manitou-mail.org
Twitter: @DanielVerite
From | Date | Subject | |
---|---|---|---|
Next Message | Moreno Andreo | 2017-04-10 15:55:41 | Re: PostgreSQL and Kubernetes |
Previous Message | John Iliffe | 2017-04-10 15:27:48 | Re: Unable to connect to Postgresql |