Fix for Windows 10 exhausted pool of TCPIP ports

Lately one of my Windows 10 machines started to behave quite strange, after about a day of use, browsing Internet was no longer possible. I could still ping resources, but not use any browser or other application requiring Internet access. A reboot fixed the problem, and then after about a day, sometimes less, the same thing happened.

After some research / troubleshooting I found the following in the event log

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

image
The event log error.

The fix

After some additional research I came across some posts on similar issues for Windows Server 2012 R2, but not Windows 10. But I decided to try the same configuration that fixes the problem on Windows Server 2012 R2, and voila. it worked.

Note: Feature updates (version upgrades) to Windows 10 is sometimes removing these values, so after upgrade, check that they are still there.

Simply create the following registry info:

HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters

TcpTimedWaitDelay
REG_DWORD: 0000001e (hex)

MaxUserPort
REG_DWORD: 0000fffe (hex)

TcpNumConnections
REG_DWORD: 00fffffe (hex)

TcpMaxDataRetransmissions
REG_DWORD: 00000005 (hex)

image
The info added to my Windows 10 machine.

About the author

Johan Arwidmark

5 2 votes
Article Rating
Subscribe
Notify of
guest
1 Comment
Newest
Oldest Most Voted
Inline Feedbacks
View all comments
Freestylin135
Freestylin135
11 months ago

Just wanted to say thank you for creating this article. I'm hopeful it will address my issue. The behavior you summarized aligns with what I was seeing.   To expand on the behavior and my observations some, I could not access any IPv4 websites using my browser, but IPv6 sites would work (e.g. I could search in google, but not open a link unless it was cached). Using cmd, I could ping websites and domain names, but using my browser NO IPv4 domain names or ip addresses would work. For example, I could not even connect to my router/gateway by… Read more »


>