[jboss-jira] [JBoss JIRA] Commented: (JGRP-615) UDP: JGroups always allocates the same ports
Bela Ban (JIRA)
jira-events at lists.jboss.org
Thu Nov 1 11:55:44 EDT 2007
[ http://jira.jboss.com/jira/browse/JGRP-615?page=comments#action_12385552 ]
Bela Ban commented on JGRP-615:
-------------------------------
I chose not to implement the kludge described below. This is overhead, especially on operating systems where it is not used.
According to http://tools.ietf.org/html/draft-larsen-tsvwg-port-randomization-02 (section 2.2), the algorithm for port allocation is:
next_ephemeral_port = 1024; /*initialization, could be random */
/* Ephemeral port selection */
count = max_ephemeral - min_ephemeral + 1;
do {
port = next_ephemeral;
if (next_ephemeral == max_ephemeral) {
next_ephemeral = min_ephemeral;
} else {
next_ephemeral++;
}
if (four-tuple is unique)
return port;
} while (count > 0);
return ERROR;
This should actually always allocate the next available port ! Need to investigate why this is not the case...
> UDP: JGroups always allocates the same ports
> --------------------------------------------
>
> Key: JGRP-615
> URL: http://jira.jboss.com/jira/browse/JGRP-615
> Project: JGroups
> Issue Type: Task
> Reporter: Bela Ban
> Assigned To: Bela Ban
> Priority: Minor
> Fix For: 2.6, 2.5.2
>
>
> In 2.5 and 2.6, JGroups always allocates the same ports with UDP and no bind_port set. This is different from 2.4, where different (increasing) ports were used.
> Investigate why this is the case, and what changed between 2.4 and 2.5.
> This doesn't happen on Windows and macOS, just on Linux.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list