On 2021-03-20, Robert Latest <
bobl...@yahoo.com> wrote:
> Hello,
Hi Robert,
> I understand how a .socket unit file with Accept=yes works: Upon connection to
> the socket, systemd starts up the associate service, it communicates with
> stdout and stdin connected to the socket, and shuts down.
>
> That is not what I want. [...]
> [...]
please start googling for more informations on the concept of sockets
under Unix flavoured operating systems.
Aside of this be told that one or the other way runing services usually
hand over incoming connections to spawned worker processes. This is true
for everything which needs more than just some milliseconds to process
the request and doesn't work with connection identifiers within the
application protocol and uses connection oriented protocols - like tcp.
SystemD socket units accept connections and spawn the specified program
to handle the specific connection. Nonetheless SystemD is permanently
listening to the specified socket. In this sense the service is
permanently available. As far as I know its not possible to write a
stdin/stdout oriented process which works with "Accept=false". Programs
which work with "Accept=false" need to be aware of the socket and need
to handle the socket by themselfs.
Concerning the concept of sockets under Unix flavoured operating
systems: As far as it can be driven it doesn't make a difference to the
program whether it listens to a network socket or to a unix domain socket.
Best regards
Henning
--
If you think technology can solve your problems you don't understand
technology and you don't understand your problems. (Bruce Schneier)