I'm trying to make 100k concurrency outgoing connection from one pc to my local server. My program can use specific ip on each connection.
Goal : 1 pc have around 100k concurrency outgoing connection.
Problem : After creating about 64k connection, i always got error on client-side : "dial tcp bind: An operation on a socket could not be performed because the system lacked sufficient buffer space or because a queue was full." I believe this is client side problem.
Already trying :
- set maximum port to 65534 via regedit (both client and server)
- using 7 ip on 1 port lan (client) --> 1 ip on 1 port lan (server) (still error)
- using 7 ip on 1 port lan (client) --> 2 ip on 1 port lan (server) (still error)
- using 7 ip on 7 port lan (client) --> 1 ip on 1 port lan (server) (still error)
- using 7 ip on 7 port lan (client) --> 2 ip on 1 port lan (server) (still error)
- using 7 ip on 7 port lan (client) --> 2 ip on 2 port lan (server) (still error)
Note :
- number 2 - 6 : each ip handle about 14300 connection.
- Ip on client : 192.168.1.31 /24 - 192.168.1.37 /24
- Ip on server : 192.168.1.20 /24 and 192.168.1.21/24
- both client and server using windows 10.
I'm browsing on many website about this case. Conclusion based on my browsing, this problem is related to TCP rules. Some people wrote that 1 Ip can handle maximum 65535 TCP connection. But, in my case, i use 7 ip on 7 port lan and still get error. Any suggestion or answer very appreciated.