[zeromq-dev] TIME_WAIT state when using source address in a TCP connection

Tom Bequin tom.bequin at studio-nyx.com
Tue Mar 29 15:48:28 CEST 2022


Hello,

We are establishing connections in TCP without any problem.
For that, we have a server binding to a local address of model "tcp://
192.168.1.1:49000".
We connect a client to a distant address of model "tcp://192.168.1.1:49000".

When using what is called in the source code "source address", to connect
using a different interface, as of model "tcp://192.168.1.2:49000;
192.168.1.1:49000", the connection is working well, but the connected
socket remains in a TIME_WAIT state so the next connection fails with port
reused.

This is not the case with standard TCP messages, so why is it happening
only in a case of a source address?

The SO_LINGER option is well set to {1, 0}. We are using Windows 10.

May you be of any help?

Tom Bequin,
Dev at NYX STUDIO.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20220329/9b416726/attachment.htm>


More information about the zeromq-dev mailing list