Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am setting up a terminal server for a small group of developers. They will all be using the SVN client to access the central SVN repository. Every project in our SVN repository contains lots of externals (some 180, some 300). All externals go to the same repository (this is the way we share code amongst projects).

SVN UPDATE fails because Windows reports that he's running out of sockets. In the event viewer we see the following message:

TCP/IP failed to establish an outgoing connection because the selected local endpoint was recently used to connect to the same remote endpoint. This error typically occurs when outgoing connections are opened and closed at a high rate, causing all available local ports to be used and forcing TCP/IP to reuse a local port for an outgoing connection. To minimize the risk of data corruption, the TCP/IP standard requires a minimum time period to elapse between successive connections from a given local endpoint to a given remote endpoint.

According to the Windows documentation, a terminal server should use socket ports starting from around 50000, and have about 16000 ports available. However, it seems that SVN gets ports from around 21000, with only about 200 ports available.

Questions:

  • Is there a way to tell SVN to group externals together using 1 socket, without closing and reopening the sockets?
  • How can you configure the ports that Windows will use for network communication? Is the documentation right (ports starting at 50000, 16000 ports available), or are our observations right (ports starting at 21000, 200 ports available)
  • Any other suggestions on how to solve this problem? (getting rid of the externals is no option at this moment).
share|improve this question
    
@Ramhound, the problem is not at the server side. The problem is at the client side. Windows will hand out port numbers to all client sockets that connect to the server, but after a socket is closed, it needs to keep the port open for a short moment (in case any pending packets come in). In this short moment, it runs out of local ports. So the problem is not the port number on the SVN server side. –  Patrick Jul 9 '13 at 14:09
add comment

1 Answer 1

up vote 1 down vote accepted

Found it.

Apparently, our IT department installed firewall client that limited the sockets to 200 per person. Increasing this to 2000 solved the problem.

Conclusion: if applications run out of sockets, don't only check the Windows configuration, but also check locally installed firewall client software.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.