Best way for an app to accept traffic on 30,000+ interfaces?

Mark D markd-freebsd-net at bushwire.net
Thu Mar 21 02:14:06 UTC 2013


On 20Mar13, Juli Mallett allegedly wrote:
> Well, the easiest thing is to add 30k aliases to your Ethernet
> interface (you may hit a limit, not sure) and then just listen on
> INADDR_ANY (or the IP6 equivalent), assuming you don't mind listening
> to other addresses you have configured as well.  The application can
> always decide to close an incoming connection that wasn't going to one
> of those 30k IP addresses.

Agreed that INADDR_ANY will fix the socket count. But what of the
interface/alias count? Is 300K ok? How about 3M aliases?

I'll spin up an instance and try it out, but I'm a little worried that
there might be something non-linear or some threshold limit that won't
necessarily be exposed by a modicum of adhoc testing.


Mark.


More information about the freebsd-net mailing list