I hate this situation (MACOSX)
$ perl -MSocket -le 'print SOMAXCONN'
128
How can I deal with more than 128 sockets? I’m using IO::Socket::INET (multiplexing with IO::Select at this time) but I have this limitation.
I was thinking in pre-fork N process (each dealing with 128 using select or poll) but I don’t know if it can work. Some Ideas?
This is a configurable limitation at the OS X kernel level. Fortunately its pretty easy to fix, but only if you have root. Here’s an article explaining how to tweak the kernel configuration. The relevant entry is
kern.ipc.somaxconn.Otherwise you can try using threads, not sure if each thread gets its own allocation of sockets, or any number of pre-forking servers on CPAN.