public inbox for [email protected]
help / color / mirror / Atom feedFrom: David G. Johnston <[email protected]>
To: Atul Kumar <[email protected]>
Cc: pgsql-general <[email protected]>
Subject: Re: issue with reading hostname
Date: Mon, 22 Apr 2024 14:54:57 -0700
Message-ID: <CAKFQuwYbhNnepQgWX_fnB-BhFp-+ujLwhYoWs_p9wdVYSsO5eg@mail.gmail.com> (raw)
In-Reply-To: <CA+ONtZ4a9mJhBX2p4Ug8NSR+tHHuVvi-Vrcm3QyGMjkwNsuRPw@mail.gmail.com>
References: <CA+ONtZ4a9mJhBX2p4Ug8NSR+tHHuVvi-Vrcm3QyGMjkwNsuRPw@mail.gmail.com>
On Mon, Apr 22, 2024 at 1:14 PM Atul Kumar <[email protected]> wrote:
>
> so below are my questions:
>
> 1. Is the psql client reading the socket file that resides in the /tmp
> directory to fetch the hostname ?
>
> 2. I saw the socket file in /tmp and it is empty. Then how is the psql
> client still reading the socket file successfully for hostname ?
>
>
>
Unix sockets are not a PostgreSQL-specific thing, they are an OS thing.
You should be able to find information on them if you search but it isn't
something our documentation is on the hook to teach.
But, in many ways, it is just a file name (Unix philosophy, everything is a
file) that programs can hook their standard input and standard output up to
such that the standard output sent by one process is directed to the
standard input of the other process. All on the fly, nothing gets
persisted into the physical file. It's a tin-can-and-string solution to
interprocess communication.
David J.
view thread (6+ messages)
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: issue with reading hostname
In-Reply-To: <CAKFQuwYbhNnepQgWX_fnB-BhFp-+ujLwhYoWs_p9wdVYSsO5eg@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox