[erlang-bugs] Erlang nodes fail to communicate if user has no capability to change SO_PRIORITY socket options.

Janek Wrobel <>
Tue Jan 25 10:09:10 CET 2011


On Mon, Jan 24, 2011 at 3:16 PM,  <> wrote:
> On Wed, 19 Jan 2011, Janek Wrobel wrote:
>> On Tue, Jan 18, 2011 at 5:15 PM,  <> wrote:
>>> On Mon, 17 Jan 2011, Serge Aleynikov wrote:
>>>> At some point I was having a similar issue with SO_PRIORITY and SO_TOS
>>>> bug
>>>> in inet_drv when trying to open a unix domain socket and pass the open
>>>> file
>>>> descriptor to gen_tcp, which failed to function properly. After
>>>> discussing
>>>> this issue with Per Hedeland he sent me the attached patch that worked
>>>> well
>>>> to solve the issue.  Perhaps it will also work in your case, and if so,
>>>> it
>>>> should be included in distribution.
>>> Seems Per's patch covers more cases - if this solves the problem, it
>>> seems
>>> like the best choice to take this one int dev instead of the smaller fix
>>> i
>>> presented earlier.
>>> Janek - have you tried this one?
>> Yes, I've tried it. It solves a different problem and does not help in
>> my case. The Per's patch makes sure that setsockopt(...,SO_PRIORITY)
>> is not called when SO_PRIORITY is not supported by a socket
>> (getsockopt(..., SO_PRIORITY) fails).
>> In my case SO_PRIORITY is supported (getsockopt(.., SO_PRIORITY
>> succeeds), but it is set to a value that user has no capabilities to
>> set.
> Oh, right. I should have looked more closely at the patch. Seems like both
> things can happen though. I think i'll do a patch that fixes both problems
> while at it.

This sounds great!

> It might take a few days though, I have some personal matters of illness to
> attend to... Hope you'll be okay with the simple patch I made earlier for
> now!

Sure, the patch is working fine for me. In the long term it will be
just much more convenient to have it included in the distribution.
This is the only thing that did not work out of the box in my setup.
Thanks Patrik for your help!


More information about the erlang-bugs mailing list