You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is the option that sets the local port used when connecting to a remote peer. Normally this is assigned by the operating system, and without this option, we can't predict which local port will be used in the tcp connection. We added this option so we could very precisely block certain paths using iptables rules to simulate netsplits for certain tests.
As for changing this in the server, it's very easy and will actually simplify code. I still think we shouldn't expose this option in help printouts, because it's a fairly confusing behavior unless you know stuff about the IP layer, and I'm not sure many users would actually have a use for it.
Activity
coffeemug commentedon Jan 27, 2014
Could you explain what
--client-portdoes a bit more? It tells rethinkdb what to port to initiate which connections on?Tryneus commentedon Jan 27, 2014
This is the option that sets the local port used when connecting to a remote peer. Normally this is assigned by the operating system, and without this option, we can't predict which local port will be used in the tcp connection. We added this option so we could very precisely block certain paths using
iptablesrules to simulate netsplits for certain tests.As for changing this in the server, it's very easy and will actually simplify code. I still think we shouldn't expose this option in help printouts, because it's a fairly confusing behavior unless you know stuff about the IP layer, and I'm not sure many users would actually have a use for it.
coffeemug commentedon Jan 28, 2014
Ah, got it, thanks!
Tryneus commentedon Jan 28, 2014
I could make this change in a few minutes if everyone agrees we should allow this option in release mode.
AtnNn commentedon Jan 28, 2014
I have implemented this already to run tests in release mode. I just have to also remove the help output, which should be easy.
If there are no objections, I'll put it up in review.
neumino commentedon Jan 28, 2014
Just for my own curiosity. Don't we use the port
29015to connect instances together?Tryneus commentedon Jan 28, 2014
That is the listening port. Each TCP packet contains both a source and destination port:
http://en.wikipedia.org/wiki/Transmission_Control_Protocol#TCP_segment_structure
In the default setup, one of those numbers will be
29015, but the--client-portoption sets the other one.coffeemug commentedon Jan 28, 2014
No objects, but I do think this option should not show up in help.
neumino commentedon Jan 28, 2014
Oh, thanks @Tryneus!