Socket Problems
-
Hello! I have a TCP/IP-Server, that listens for connections from a electronic device. The device connects to the server and the server build another IP-Connection to the electronic. It may happen, that the electronic has to reboot and cannot close the connection properly. The server has a connection-watchdog, that checks when the last message came in from the electronic and tries to close the connection if the electronic didn´t send a message since a certain time. Since the electronic cannot answer this close-request the connection seems to remain open, at least that´s what "netstat" tells me ("Wait for FIN", or "Last message was ACK"). Also it may happen, that the electronic tries to connect again, but then the server send´s just an "ACK" instead of "SYN/ACK", what makes the electronic retry to open the connection with "SYN". (Traced with WireShark) Is there a way to force the closing the connection, clear the open/waiting ports and enable the server to accept a new connection from the same electronic on the same port from the same IP? Thanks J.
-
Hello! I have a TCP/IP-Server, that listens for connections from a electronic device. The device connects to the server and the server build another IP-Connection to the electronic. It may happen, that the electronic has to reboot and cannot close the connection properly. The server has a connection-watchdog, that checks when the last message came in from the electronic and tries to close the connection if the electronic didn´t send a message since a certain time. Since the electronic cannot answer this close-request the connection seems to remain open, at least that´s what "netstat" tells me ("Wait for FIN", or "Last message was ACK"). Also it may happen, that the electronic tries to connect again, but then the server send´s just an "ACK" instead of "SYN/ACK", what makes the electronic retry to open the connection with "SYN". (Traced with WireShark) Is there a way to force the closing the connection, clear the open/waiting ports and enable the server to accept a new connection from the same electronic on the same port from the same IP? Thanks J.
Yikes. No way to configure the device to use something easier like UDP? Going to be a massive pain to hook that deep into the network stack :/
Mark Churchill Director Dunn & Churchill Free Download:
Diamond Binding: The simple, powerful, reliable, and effective data layer toolkit for Visual Studio. -
Yikes. No way to configure the device to use something easier like UDP? Going to be a massive pain to hook that deep into the network stack :/
Mark Churchill Director Dunn & Churchill Free Download:
Diamond Binding: The simple, powerful, reliable, and effective data layer toolkit for Visual Studio. -
Hello! I have a TCP/IP-Server, that listens for connections from a electronic device. The device connects to the server and the server build another IP-Connection to the electronic. It may happen, that the electronic has to reboot and cannot close the connection properly. The server has a connection-watchdog, that checks when the last message came in from the electronic and tries to close the connection if the electronic didn´t send a message since a certain time. Since the electronic cannot answer this close-request the connection seems to remain open, at least that´s what "netstat" tells me ("Wait for FIN", or "Last message was ACK"). Also it may happen, that the electronic tries to connect again, but then the server send´s just an "ACK" instead of "SYN/ACK", what makes the electronic retry to open the connection with "SYN". (Traced with WireShark) Is there a way to force the closing the connection, clear the open/waiting ports and enable the server to accept a new connection from the same electronic on the same port from the same IP? Thanks J.