* Aliased interfaces and binded sockets
@ 2005-07-13 20:49 Rafi Kosot
0 siblings, 0 replies; only message in thread
From: Rafi Kosot @ 2005-07-13 20:49 UTC (permalink / raw)
To: linux-kernel
I have a few aliased interfaces defined on my eth device (eth0:0,
eth0:1, etc.) each alias has a different ip address.
I noticed, that when binding a socket to an ip address (with port=0 -
"don't care"), for outgoing connection, the port number allocated to
the different ip address are distinct (i.e. no overlap). More than
that - when the number of connection exceeds ~60K (in total over all
the aliased interfaces) I get an error EADDRINUSE, though on each one
of the aliased interfaces the number of connections is less than
10,000. It seems like all the aliased interfaces are actually
considered as a single interface!
I looked for the problem in inet section of the kernel, specifically
the function tcp_v4_get_port(..), which is responsible for port
allocation when binding with port=0. Ss far as I understand the ports
are allocated regardless of the interface involved. In other words -
only 64K tcp enpoints are possible, over all interfaces. Is this true?
Has someone noticed the phenomena? Is it possible to bind more than
64K ports over different aliased interfaces?
(Just for the record, I used ulimit -n 128000 so there's no ulimit
problem here).
thanks, Rafi
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-07-13 20:52 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-07-13 20:49 Aliased interfaces and binded sockets Rafi Kosot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox