Hello Everyone,
Again, i'm back with this problem with some news...

I have reproduce the problem :

The configuration :
1 process based on ICS 8.34 with :
a socket server with 4 clients connected (they only receive data) (TCP).
3 connection etablished to 3 different socket server from network devices
(TCP).


Everything worked for 28 Hours.
I started another application which freezed the computer for 1-2 seconds,
and now the problem happen :

Problems :
1) No data output the application
No more data is sent from my application to the 4 clients. (but everyone
says it is well connected).

2) No more data are computed by my application.
I do not received new data. (everyone is connected (netstat), and wireshark
show me the data are well received by the computer).

What can i see :
The processus is not freezed.
All clients show that all TCP connection from and to everyone are in
etablish state (from netstat).
Wireshark show that data from the 3 clients to the processus are well
received on the network interface.
TWSocket client object say that i'm still connected to the 3 clients !

I reproduce this bug for the first time since more than one year and outside
of any IDE so i cannot search were does it really stuck...
I will now try to reproduce the problem from an IDE...

In this time, did you already ear something like that with ICS ?
Have you any idea where data can be blocked, and in this state what can i do
more than inspecting by wireshark and netstat ???

Thank you.

Best regards,
Moro Alexandre.



-----Message d'origine-----
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Moro
Alexandre
Envoyé : mardi 11 octobre 2016 08:37
À : 'ICS support mailing'
Objet : Re: [twsocket] TWSocket Client Timeout.

Hello everyone,

I'm back, and i got good news, i finaly found what was going on :

It is simply a problem half open connection :


The connection between the server and the client (using TWSocket) is
forwarded althrough a Wifi connection (based on 868Mhz, which is really
unstable).
Sometimes when the server sent somes frames to the client, the server
doesn't receive the ACK and the server close the connection from the client.
But, this client doesn't know it, so TWSocket thinks the connection is still
open...

I checked it with netstat on both server and client and it is very clear now
!

To better handle this situation, i changed KeepAlive timeout like that :

mpWSocket->KeepAliveOnOff = wsKeepAliveOnCustom; KeepAliveTime = 25 * 
mpWSocket->1000;

And now, we clearly see that the socket closed itself after these 25 seconds
without data received (when the Wifi is down) and try to reconnect...


Sorry to loose your time, maybe it can help someone encoutered the same
problem.


Best,
Alexandre.


-----Message d'origine-----
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de Moro
Alexandre Envoyé : mercredi 5 octobre 2016 08:44 À : 'ICS support mailing'
Objet : Re: [twsocket] TWSocket Client Timeout.

Hello Stephen,

Thank you for sharing and giving me a way to search about.

I searched about theses function in my whole source code but these are not
used.

I looked for something similar like low level code but i did not really find
something interessting...

So wait and see...


-----Message d'origine-----
De : TWSocket [mailto:twsocket-boun...@lists.elists.org] De la part de
Stephen Dickason Envoyé : mardi 4 octobre 2016 18:52 À : ICS support mailing
Objet : Re: [twsocket] TWSocket Client Timeout.

Please pardon me for butting in.  I can share what I found broke ICS for me
and you can check if you have anything similar.

I used a separate piece of low level code (not ICS) in my about form that
displayed the host name and IP address of the user's PC, it used
winsock.gethostname, WSAStartup($101,...) and WSACleanup.  (I don't remember
which one was the culprit.) This I found broke any open socket connections
that I had and only way to see if they were broken was something like cmd's
netstat -a. It was rather a bother, as not many people check the about box,
so was quite random, showed no errors and was pretty annoying.
I fixed it a long time ago by using internal ICS functions instead.

Hope it helps.


Stephen Dickason
Senior Developer - Managed Services
  Email: sdicka...@elcb.co.za

ELCB Information Services (Pty) Ltd
Customer Service Email  e...@elcb.co.za * www.elcb.co.za E A S T  L O N D O
N
Tel: +27(43)  704 0700
Fax: +27(43) 704 0701
J O H A N N E S B U R G
Tel: +27(11) 879 6179
Fax: +27(11) 454 0384
P O R T  E L I Z A B E T H
Tel: +27(41) 373 0529
Fax: +27(86) 650 0135
Disclaimer

> -----Original Message-----
> From: TWSocket [mailto:twsocket-boun...@lists.elists.org] On Behalf Of 
> Moro Alexandre
> Sent: Tuesday, October 4, 2016 17:19
> To: 'ICS support mailing'
> Subject: Re: [twsocket] TWSocket Client Timeout.
>
> Hi Angus,
>
> Sorry to bother you, please find more details :
>
> In fact, an user use our application to retrieve data from a device by 
> a TCP connection throught TWSocket.
>
> The problem is that after a certain time (between 5 and 8 hours) the 
> data stop being received but TWSocket still indicate that it is connected.
>
> The user has reproduce the problem multiple times.
>
> This problem only appears since one year : when we have updated C++ 
> Builder and ICS :
>
> From Borland Builder 6 to Embarcadero XE3 From ICS 5.25 to ICS r1196.
>
> I do not have more details since i can not reproduce this problem myself.
> But we are going to reproduce it this weekend.
>
> Finaly, i just see that you have fix some problems with timeout and 
> WSAESHUTDOWN in the version r1280 and r1279, so since it is related to 
> time maybe it fix my problem of 5/8 Hours...
>
> I cannot reproduce the original problem, unfortunately i cannot try it 
> for the moment !
>
> Thanks again !!!
>
> Alexandre.
>
>
--
To unsubscribe or change your settings for TWSocket mailing list please goto
http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


--
To unsubscribe or change your settings for TWSocket mailing list please goto
http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


--
To unsubscribe or change your settings for TWSocket mailing list please goto
http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to