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

pan <>
Mon Jan 24 15:16:50 CET 2011


Hi,

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.

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!
>
> I've sent an email to , maybe those guys will
> help to determine if this is a generic problem that can affect other
> Erlang users: http://www.spinics.net/lists/netdev/msg153009.html
>
It would be interesting to hear the reason for this strange 
SO_PRIORITY behaviour, although i think we could safely implement the 
workaround anyway, after all, the whole resetting of SO_PRIORITY is a 
workaround to start with...
> Cheers,
> Janek
>
Cheers,
/Patrik


More information about the erlang-bugs mailing list