This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes Sockets and Internet Protocols and the fly likes what could possibly  cause a UDP Socket server to be closed ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "what could possibly  cause a UDP Socket server to be closed ?" Watch "what could possibly  cause a UDP Socket server to be closed ?" New topic
Author

what could possibly cause a UDP Socket server to be closed ?

Elhanan Maayan
Ranch Hand

Joined: May 04, 2009
Posts: 113
hi...

we have a socket server which accepts around 27 multiple client connection from different devices (Access Points if you must know) , the problem is, that on a specific machine running windows 2008 sr2, these sockets tend be closed down almost a few seconds after it's open with the exception of:
java.net.SocketException: socket closed
at java.net.PlainDatagramSocketImpl.receive0(Native Method)
at java.net.PlainDatagramSocketImpl.receive(PlainDatagramSocketImpl.java:145)
at java.net.DatagramSocket.receive(DatagramSocket.java:725)
at aeroscout.dev.net.UdpServerProtocol.receive(UdpServerProtocol.java:70)
.

and
java.net.SocketException: Socket is closed
at java.net.DatagramSocket.send(DatagramSocket.java:590)
at aeroscout.dev.net.UdpServerProtocol.send(UdpServerProtocol.java:90)
at aeroscout.dev.net.CommTerminal$DataWriter.run(CommTerminal.java:380)

a few things.

this is java 6.

if you try to open around 2 connections that won't happen, we don't exactly the threshold that starts to break connections.

the machines also have an IPV6 card, but we are not using it.

the machines didn't receive any updates (it's not even connected to the internet) from 09/2012, the issues started from 02/2013

the event log doesn't have any special errors i should notice.
this is the netstat of the active connections we have:

Active Connections

Proto Local Address Foreign Address State PID
TCP 0.0.0.0:135 0.0.0.0:0 LISTENING 716
TCP 0.0.0.0:443 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:445 0.0.0.0:0 LISTENING 4
TCP 0.0.0.0:1411 0.0.0.0:0 LISTENING 5444
TCP 0.0.0.0:1433 0.0.0.0:0 LISTENING 4444
TCP 0.0.0.0:1919 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:1920 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:1921 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:1922 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:2160 0.0.0.0:0 LISTENING 1504
TCP 0.0.0.0:2161 0.0.0.0:0 LISTENING 1468
TCP 0.0.0.0:2260 0.0.0.0:0 LISTENING 1504
TCP 0.0.0.0:3052 0.0.0.0:0 LISTENING 1468
TCP 0.0.0.0:3389 0.0.0.0:0 LISTENING 2836
TCP 0.0.0.0:6547 0.0.0.0:0 LISTENING 1468
TCP 0.0.0.0:8080 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:8082 0.0.0.0:0 LISTENING 5444
TCP 0.0.0.0:8800 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:8801 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:47001 0.0.0.0:0 LISTENING 4
TCP 0.0.0.0:49152 0.0.0.0:0 LISTENING 440
TCP 0.0.0.0:49153 0.0.0.0:0 LISTENING 868
TCP 0.0.0.0:49154 0.0.0.0:0 LISTENING 916
TCP 0.0.0.0:49187 0.0.0.0:0 LISTENING 536
TCP 0.0.0.0:49281 0.0.0.0:0 LISTENING 484
TCP 0.0.0.0:49293 0.0.0.0:0 LISTENING 3124
TCP 0.0.0.0:50558 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:50568 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:50578 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:61616 0.0.0.0:0 LISTENING 1588
TCP 0.0.0.0:61617 0.0.0.0:0 LISTENING 5444
TCP 10.8.100.236:139 0.0.0.0:0 LISTENING 4
TCP 10.8.100.236:2161 10.8.100.236:49188 ESTABLISHED 1468
TCP 10.8.100.236:8080 10.8.110.107:52006 ESTABLISHED 1588
TCP 10.8.100.236:8080 10.8.110.121:51001 ESTABLISHED 1588
TCP 10.8.100.236:8080 10.8.115.118:49661 ESTABLISHED 1588
TCP 10.8.100.236:8080 10.8.125.111:51129 ESTABLISHED 1588
TCP 10.8.100.236:8080 10.8.131.151:56069 ESTABLISHED 1588
TCP 10.8.100.236:49188 10.8.100.236:2161 ESTABLISHED 1504
TCP 10.8.100.236:50568 10.8.100.236:50647 ESTABLISHED 1588
TCP 10.8.100.236:50592 10.8.100.236:61616 ESTABLISHED 1588
TCP 10.8.100.236:50593 10.8.100.236:61616 ESTABLISHED 1588
TCP 10.8.100.236:50647 10.8.100.236:50568 ESTABLISHED 1588
TCP 10.8.100.236:61616 10.8.100.236:50592 ESTABLISHED 1588
TCP 10.8.100.236:61616 10.8.100.236:50593 ESTABLISHED 1588
TCP 10.8.185.10:139 0.0.0.0:0 LISTENING 4
TCP 127.0.0.1:1411 127.0.0.1:50542 TIME_WAIT 0
TCP 127.0.0.1:1411 127.0.0.1:50576 ESTABLISHED 5444
TCP 127.0.0.1:1411 127.0.0.1:50584 ESTABLISHED 5444
TCP 127.0.0.1:1433 127.0.0.1:50546 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50547 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50548 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50549 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50550 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50551 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50552 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50553 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50554 ESTABLISHED 4444
TCP 127.0.0.1:1433 127.0.0.1:50555 ESTABLISHED 4444
TCP 127.0.0.1:8005 0.0.0.0:0 LISTENING 1588
TCP 127.0.0.1:8080 127.0.0.1:50589 ESTABLISHED 1588
TCP 127.0.0.1:8080 127.0.0.1:50652 FIN_WAIT_2 1588
TCP 127.0.0.1:8080 127.0.0.1:50653 FIN_WAIT_2 1588
TCP 127.0.0.1:31001 127.0.0.1:32000 ESTABLISHED 5444
TCP 127.0.0.1:32000 0.0.0.0:0 LISTENING 5080
TCP 127.0.0.1:32000 127.0.0.1:31001 ESTABLISHED 5080
TCP 127.0.0.1:49191 127.0.0.1:49192 ESTABLISHED 1468
TCP 127.0.0.1:49192 127.0.0.1:49191 ESTABLISHED 1468
TCP 127.0.0.1:49194 0.0.0.0:0 LISTENING 4444
TCP 127.0.0.1:50167 0.0.0.0:0 LISTENING 1468
TCP 127.0.0.1:50546 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50547 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50548 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50549 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50550 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50551 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50552 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50553 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50554 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50555 127.0.0.1:1433 ESTABLISHED 1588
TCP 127.0.0.1:50562 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50564 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50565 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50566 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50569 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50570 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50571 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50572 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50576 127.0.0.1:1411 ESTABLISHED 1588
TCP 127.0.0.1:50582 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50584 127.0.0.1:1411 ESTABLISHED 1588
TCP 127.0.0.1:50586 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50589 127.0.0.1:8080 ESTABLISHED 1588
TCP 127.0.0.1:50596 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50597 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50598 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50599 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50600 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50611 127.0.0.1:61616 ESTABLISHED 1588
TCP 127.0.0.1:50652 127.0.0.1:8080 CLOSE_WAIT 3712
TCP 127.0.0.1:50653 127.0.0.1:8080 CLOSE_WAIT 3712
TCP 127.0.0.1:50655 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50656 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50657 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50658 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50659 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50660 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50661 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:50662 127.0.0.1:8080 TIME_WAIT 0
TCP 127.0.0.1:61616 127.0.0.1:50562 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50564 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50565 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50566 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50569 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50570 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50571 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50572 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50582 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50586 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50596 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50597 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50598 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50599 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50600 ESTABLISHED 1588
TCP 127.0.0.1:61616 127.0.0.1:50611 ESTABLISHED 1588
TCP 127.0.0.1:61617 127.0.0.1:50543 TIME_WAIT 0
TCP [::]:135 [::]:0 LISTENING 716
TCP [::]:443 [::]:0 LISTENING 1588
TCP [::]:445 [::]:0 LISTENING 4
TCP [::]:1411 [::]:0 LISTENING 5444
TCP [::]:1433 [::]:0 LISTENING 4444
TCP [::]:1919 [::]:0 LISTENING 1588
TCP [::]:1920 [::]:0 LISTENING 1588
TCP [::]:1921 [::]:0 LISTENING 1588
TCP [::]:1922 [::]:0 LISTENING 1588
TCP [::]:2160 [::]:0 LISTENING 1504
TCP [::]:2161 [::]:0 LISTENING 1468
TCP [::]:2260 [::]:0 LISTENING 1504
TCP [::]:3052 [::]:0 LISTENING 1468
TCP [::]:3389 [::]:0 LISTENING 2836
TCP [::]:8082 [::]:0 LISTENING 5444
TCP [::]:8800 [::]:0 LISTENING 1588
TCP [::]:8801 [::]:0 LISTENING 1588
TCP [::]:47001 [::]:0 LISTENING 4
TCP [::]:49152 [::]:0 LISTENING 440
TCP [::]:49153 [::]:0 LISTENING 868
TCP [::]:49154 [::]:0 LISTENING 916
TCP [::]:49187 [::]:0 LISTENING 536
TCP [::]:49281 [::]:0 LISTENING 484
TCP [::]:49293 [::]:0 LISTENING 3124
TCP [::]:50558 [::]:0 LISTENING 1588
TCP [::]:50568 [::]:0 LISTENING 1588
TCP [::]:50578 [::]:0 LISTENING 1588
TCP [::]:61616 [::]:0 LISTENING 1588
TCP [::]:61617 [::]:0 LISTENING 5444
TCP [::1]:49194 [::]:0 LISTENING 4444
UDP 0.0.0.0:123 *:* 968
UDP 0.0.0.0:500 *:* 916
UDP 0.0.0.0:1434 *:* 1976
UDP 0.0.0.0:2160 *:* 1504
UDP 0.0.0.0:2161 *:* 1468
UDP 0.0.0.0:4500 *:* 916
UDP 0.0.0.0:5355 *:* 156
UDP 0.0.0.0:7846 *:* 1468
UDP 0.0.0.0:12091 *:* 5444
UDP 0.0.0.0:12092 *:* 5444
UDP 0.0.0.0:37008 *:* 5444
UDP 0.0.0.0:56622 *:* 1468
UDP 10.8.100.236:137 *:* 4
UDP 10.8.100.236:138 *:* 4
UDP 10.8.185.10:137 *:* 4
UDP 10.8.185.10:138 *:* 4
UDP 127.0.0.1:54615 *:* 916
UDP 127.0.0.1:55884 *:* 3712
UDP 127.0.0.1:62758 *:* 4356
UDP 127.0.0.1:62965 *:* 1912
UDP 127.0.0.1:64544 *:* 156
UDP 127.0.0.1:65166 *:* 536
UDP [::]:123 *:* 968
UDP [::]:500 *:* 916
UDP [::]:1434 *:* 1976
UDP [::]:2160 *:* 1504
UDP [::]:2161 *:* 1468
UDP [::]:4500 *:* 916
UDP [::]:7846 *:* 1468
UDP [::]:12091 *:* 5444
UDP [::]:12092 *:* 5444
UDP [::]:37008 *:* 5444
UDP [::]:56622 *:* 1468



 
GeeCON Prague 2014
 
subject: what could possibly cause a UDP Socket server to be closed ?