<div dir="ltr"><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, Feb 13, 2022 at 2:03 AM Wol <<a href="mailto:antlists@youngman.org.uk">antlists@youngman.org.uk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">More fun getting things to work ... :-)<br>
<br>
So I've got a service, scarletdme.service, which fires up my db backend <br>
for running interactively. However, I also need a socket service for <br>
remote connections.<br>
<br>
I've got the xinetd files, but if I'm running systemd, I want to use <br>
systemd :-)<br>
<br>
So I've written scarletdme.socket, and scarletdme@.service, but the more <br>
I read, the more I don't understand ...<br>
<br>
Do I enable scarletdme.socket the same as anything else eg "systemctl <br>
enable scarletdme.socket"? How does it know the difference between <br>
scarletdme.service and scarletdme@.service? I get the impression I need <br>
to put something in the .socket file to make it use scarletdme@ rather <br>
than scarletdme?<br></blockquote><div><br></div><div>If it's a 'nowait' socket (which is "[Socket] Accept=yes" in systemd terms), then it will use the templated @.service, starting a new instance for each "accepted" socket (i.e. instance per connection). See oidentd.socket for comparison.<br></div><div><br></div><div>Otherwise (by default) it uses the non-templated service and directly gives it the "listening" socket, letting the service itself handle accept().<br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<br>
<br>
And once I've got all that sorted, I'm betting I'm going to have grief <br>
getting it to work properly, so while it's not much to do with systemd, <br>
is there any way I can get systemd to log all traffic back and forth so <br>
I can debug it?<br></blockquote><div><br></div><div>No, the traffic doesn't even go through systemd in the first place.<br clear="all"></div></div><br>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr">Mantas Mikulėnas</div></div></div>