How to Find Client Network cable is unplugged or plugged in
-
hi in my application i am sending message to a client using socket(TCP IP) now if the clients network cable is unplugged ...still the messages which i am sending are going without any error .....now this is creating a problem so if any one knows how to know the clients network cable is plugged in or not please do let me know ......as i am strucked at this point regards sindhu tiwari
its me sid
-
hi in my application i am sending message to a client using socket(TCP IP) now if the clients network cable is unplugged ...still the messages which i am sending are going without any error .....now this is creating a problem so if any one knows how to know the clients network cable is plugged in or not please do let me know ......as i am strucked at this point regards sindhu tiwari
its me sid
Hehehe - grins TCP. Yup TCP doesn't have a mechanism to detect it automatically..and it's because any network would have frequent "negligible" disturbances that TCP would not take it as a "disconnect". The only way I knew was to keep a routine to check clients PULSEs . Server->"Are you there?" Client0->"Yup".:cool: Client1->"Yup".:cool: Client2->...:suss:. clientList[2].remove(); :-\
OK,. what country just started work for the day ? The ASP.NET forum is flooded with retarded questions. -Christian Graus Best wishes to Rexx[^]
-
Hehehe - grins TCP. Yup TCP doesn't have a mechanism to detect it automatically..and it's because any network would have frequent "negligible" disturbances that TCP would not take it as a "disconnect". The only way I knew was to keep a routine to check clients PULSEs . Server->"Are you there?" Client0->"Yup".:cool: Client1->"Yup".:cool: Client2->...:suss:. clientList[2].remove(); :-\
OK,. what country just started work for the day ? The ASP.NET forum is flooded with retarded questions. -Christian Graus Best wishes to Rexx[^]
the question which i have asked is indirectly abt the pinging in this scenario i can do one thing send some bytes to client and in reply to that recive some bytes from client ............ but what i really wanna do is that once a message is send from the server it must be in a state to know weather the client system is in the network or not ......... dude if u have any idea abt this then let me know Sid
its me sid
-
the question which i have asked is indirectly abt the pinging in this scenario i can do one thing send some bytes to client and in reply to that recive some bytes from client ............ but what i really wanna do is that once a message is send from the server it must be in a state to know weather the client system is in the network or not ......... dude if u have any idea abt this then let me know Sid
its me sid
Yes, that's possible. Check for
IPPROTO_ICMP
. But I would only suggest a mechanism where the client *replies* to our pulse-ping. Because imagine a case, the network is out and in few seconds it's up again. Now you send your ICMP query this would say that the client is still up. But it's a reincarnated client, it doesn't hold up the old connection. So your client list would go meaningless. So make a seperate thread that keeps pinging for clients pulses and mainting the clients.
OK,. what country just started work for the day ? The ASP.NET forum is flooded with retarded questions. -Christian Graus Best wishes to Rexx[^]