On Sun, Jan 5, 2014 at 1:44 PM, Zbigniew Jędrzejewski-Szmek <zbys...@in.waw.pl> wrote: > 3. The strategy of dup()ing the socket doesn't work. I wrote > a simple server in python which logs the connections [2], and hooked > it up into systemd [3-4] (*). If REUSEPORT was working correctly, > each connection would be handled by just one instance, either created > previously, or newly created by systemd for this connection. But > I see the same connection being accept()ed by one of the instances > and systemd itself spawning a new instance. I'm pretty sure that what > Lennart wrote before, that you need to create a new socket bound to > the same port for REUSEPORT to take effect, is true.
I've also seen pretty even (but not perfect, especially with event-based designs) distribution with multiple processes simply running accept() on the same inherited socket. _______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel