n-acd: use separate seed state for each probe of the same acd#10
n-acd: use separate seed state for each probe of the same acd#10bengal wants to merge 1 commit intonettools:masterfrom
Conversation
Currently, all the probes of an acd instance share the same seed state. This means that the state is updated by all the probes, and as a consequence they get different jitters for the wait timeouts; therefore the order in which addresses become available (and can configured on the interface) is not deterministic. Keep a separate seed state for each probe, initialized from the acd seed. This ensures that all the probes use the same timeouts when sending probe requests, and that in case of no collision, addresses are available in the order of probe start. According to RFC 5227, the reason for the initial random delay is that "This initial random delay helps ensure that a large number of hosts powered on at the same time do not all send their initial probe packets simultaneously" There is no mention that different addresses on the same interface should have a different delay.
Currently, all the probes of an acd instance share the same seed state. This means that the state is updated by all the probes, and as a consequence they get different jitters for the wait timeouts; therefore the order in which addresses become available (and are configured on the interface) is not deterministic. Keep a separate seed state for each probe, initialized from the acd seed. This ensures that all the probes use the same timeouts when sending probe requests, and that in case of no collision, addresses are available in the order of probe start. n-acd pull request: nettools/n-acd#10
|
The code schedules a timer. If your task is moved to another CPU, the clocks might be slightly out of sync and you can still end up with probes being reordered. I am not sure this is really worthwhile. You can always delay address setup until all probes for all addresses finished, in case this is the desired behavior. I am unsure what you are trying to achieve. Why do you need probing to be deterministic? Shouldn't any upper dependency inevitably use some state machine to track dependencies, rather than relying on the lower protocols to be ordered on the network layer? Lastly, even if you do have a desire for deterministic behavior, why not rather add |
Currently, all the probes of an acd instance share the same seed state. This means that the state is updated by all the probes, and as a consequence they get different jitters for the wait timeouts; therefore the order in which addresses become available (and are configured on the interface) is not deterministic. Keep a separate seed state for each probe, initialized from the acd seed. This ensures that all the probes use the same timeouts when sending probe requests, and that in case of no collision, addresses are available in the order of probe start. n-acd pull request: nettools/n-acd#10 (cherry picked from commit 2372791)
Currently, all the probes of an acd instance share the same seed state. This means that the state is updated by all the probes, and as a consequence they get different jitters for the wait timeouts; therefore the order in which addresses become available (and can configured on the interface) is not deterministic.
Keep a separate seed state for each probe, initialized from the acd seed. This ensures that all the probes use the same timeouts when sending probe requests, and that in case of no collision, addresses are available in the order of probe start.
According to RFC 5227, the reason for the initial random delay is that
There is no mention that different addresses on the same interface should have a different delay.