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.

Today my machine stopped being able to access the internet. I can still access some local network resources. When I looked in the error log I saw following tcpip warning:

A request to allocate an ephemeral port number from the global UDP port space has failed due to all such ports being in use.

I ran netstat -anob and in the output DNScache is listed thousands of times (starting from port 50000 up to 65536).

netstat output

This is the second time that this has happened to me. Killing the DNSClient process based on the instructions found here did work, but I would like to figure out what is causing this problem.

Update: When this problem happens I am still able to get online with programs that used DNS to resolve a hostname before the problem started. For example, I am able to continue chatting with friends with Pidgin. I am also able to connect to websites directly using the IP address.

share|improve this question
    
Update: This has happened to me multiple times this week. I would really like some help in tracking down what is causing the problem, so I am adding a bounty. –  cmorse May 6 '13 at 16:49
    
Check your router settings, as a number have a couple of them have a setting that limits the number of connections to the same host, try restarting the router to see if that clears the problem, if so then look in the advance settings under DoS and look for number of connections per host –  Ian May 6 '13 at 17:01
    
@Ian I'm running dd-wrt on my router. I logged in and checked and there were 143 active IP connections (3% of maximum). I can check again tomorrow to see if the number is higher when the problem happens. I have seen the number of connections go well over 1,000 without any problems. –  cmorse May 6 '13 at 17:18
1  
What's actually happening here is that the Dnscache service is binding all the listening ports it's permitted to use, and then failing when it tries to bind another one. I haven't found info on cause, and I don't have a Windows 8 box with which to experiment; in the meantime, I'd advise disabling the Dnscache service via the services console (Start -> Run -> services.msc, OK). Running without it will prevent name resolution results being cached, which will slow down network requests slightly as more DNS queries are necessary, but should put a stop to the much worse problem you're seeing. –  Aaron Miller May 6 '13 at 17:31
1  
Ideally, so would I -- but that may take some time, and disabling the service looks like it may offer a decent stopgap so that DNS resolution doesn't randomly fail, and require manual intervention to resume, between now and whenever a solution presents itself. –  Aaron Miller May 6 '13 at 18:05

1 Answer 1

up vote 5 down vote accepted

I figured it out! It was the HealthAlertsSvc (Windows Server Health Service). It looks like the health service on my Windows Home Server 2011 machine crashed, and that revealed a bug in the client side HealthAlertsSvc where it wouldn't release the UDP ports correctly.

To double check that this was the case. I disabled the service on the server side and on my desktop. As soon as I re-enabled the service on my desktop the number of UDP connections that were left open started to slowly grow. After I re-started the service on the server, a large number of the UDP connections were immediately released, and the list no longer grew in size.

share|improve this answer

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.