I am writing socket.io-client node.js bot app in order to test performance of my socket.io based server application also running under node. 

Usually the server runs ubuntu linux but I also have the same server app (node.js, nginx, socket.io) installed and configured on my local dev machine. 

If I start my bot-"script" and launch 200 bots that create individual connections to the server I have no problem whatsoever if I do it to the real server(s), the linux servers. 

But if I connect to my local os x based "server" I cannot really get over ~120 connections. 

I get disconnects, stale sockets, and an infinite loop of disconnect/reconnect which under the standard settings of socket.io will just take longer and longer to complete (delayed reconnection attempt). 

My local dev machine is under almost 0% load during such a test, so it is not related to memory or processor. 

I have tried the same bot-script from a second local machine, to ensure the issue was not related to the bots running on the same machine as the server. But I get the same issue. 

As soon as I point the bot-script towards the real servers I have no issues whatsoever. 

When I am in the range where the issue occurs, i.e. pushing with more than 120 clients, I have tried to access my local dev-server with a browser (the real user-scenario) and refresh many times. Sometimes I get a "internal server 500". 

Makes me think that maybe this is not socket.io related by rather nginx? or some other basic socket limitation on a regular os x (non server) machine?