linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tobias Oberstein <tobias.oberstein@gmail.com>
To: Eduardo Silva <edsiper@gmail.com>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: SO_REUSEPORT and Unix domain sockets
Date: Sun, 21 Sep 2014 15:50:43 +0200	[thread overview]
Message-ID: <541ED7B3.6050306@gmail.com> (raw)
In-Reply-To: <CAMAQheOpXxa-ndT1EuOqJgae3yzEWbRTLMs+y800S930w-xKsw@mail.gmail.com>

Am 20.09.2014 03:44, schrieb Eduardo Silva:
>>
>> How can this be used for sockets of type AF_UNIX?
>>
>> I can only get it working with TCP sockets, not Unix domain sockets.
>>
>> When using TCP, the incoming clients will get nicely balanced to all
>> processes listening. With Unix domain sockets, the incoming clients all get
>> connected only to the last started process.
>>
>> The test code (Python) I was trying is here:
>>
>> http://stackoverflow.com/questions/23742368/can-so-reuseport-be-used-on-unix-domain-sockets
>>
>> Any hints appreciated,
>> /Tobias
>
>
> Looking at the original patch looks like the implementation is only
> done for TCP and UDP:
>
>       http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=c617f398edd4db2b8567a28e899a88f8f574798d
>

Ok, I see. Unfortunate.

> UNIX domain sockets use the file system as the address name space, so
> SO_REUSEPORT would not be applicable.
>

Yes, in case of Unix domain sockets, it's about "reusing paths", not ports.

Such an option for in-kernel load-balancing of Unix domain sockets would 
be useful ..

/Tobias

      reply	other threads:[~2014-09-21 13:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-27  9:55 SO_REUSEPORT and Unix domain sockets Tobias Oberstein
2014-09-20  1:44 ` Eduardo Silva
2014-09-21 13:50   ` Tobias Oberstein [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=541ED7B3.6050306@gmail.com \
    --to=tobias.oberstein@gmail.com \
    --cc=edsiper@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).