I am really interested in the bug report :)
From the RFC-4601(4.3.2):
A router's idea of the current
DR on an interface can change when a PIM Hello message is received,
when a neighbor times out, or when a router's own DR Priority
changes. If the router becomes the DR or ceases to be the DR, this
will normally cause the DR Register state machine to change state.
Subsequent actions are determined by that state machine.
The RFC, imo, doesn't really specify if you should do DR every hello
received or not. It implies
the original code prior to ee83d33acd....
donald
On 6/16/15 5:02 PM, Everton Marques wrote:
Donald,
The DR election for every hello message is actually needed.
This change entered the code as a fix for a defect reported by a
pimd user.
I can't remember the reasoning, but I could find the commit which
fixed the issue:
https://github.com/udhos/qpimd/commit/ee83d33acde3c77d238f72cd294ccbbb88ee23ee
I will try to recollect, based on my private email exchanges, the
exact reasoning behind this need.
Everton
On Tue, Jun 16, 2015 at 5:26 PM, Donald Sharp
<[email protected] <mailto:[email protected]>> wrote:
The DR election is occurring on every hello received.
This is because the hello receive packet returns a 0
for any successfully received packet. PIMD then looked
at the 0 returned and did a DR election.
Code was inspected for the cases where DR should happen:
(A) Interface ip address change
(B) DR priority in hello packet changes
(C) Received a new neighbor on an interface
(D) Neighbor timer pops.
Each of these initiate a DR election in the code currently.
Testing was initiated on a pim network:
tor-11# show ip pim designated-router
NonPri: Number of neighbors missing DR Priority hello option
Interface Address DR Uptime Elections
Changes NonPri
br1 20.0.15.1 20.0.15.1 00:08:16 1 1 0
swp1 169.254.0.10 169.254.0.10 00:08:16 2 1 0
swp2 169.254.0.26 169.254.0.26 00:08:16 2 1 0
tor-11#
As you can see Elections == 2. This is because pimd performs
an election on (A) and (C) above. I see no need to modify
(A) to check if we have any knowledge of the interface before
this call.
---
pimd/pim_pim.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/pimd/pim_pim.c b/pimd/pim_pim.c
index f6f4c95..adcb296 100644
--- a/pimd/pim_pim.c
+++ b/pimd/pim_pim.c
@@ -212,9 +212,6 @@ int pim_pim_packet(struct interface *ifp,
uint8_t *buf, size_t len)
ip_hdr->ip_src,
pim_msg + PIM_MSG_HEADER_LEN,
pim_msg_len - PIM_MSG_HEADER_LEN);
- if (!result) {
- pim_if_dr_election(ifp); /* PIM Hello message is received */
- }
return result;
}
--
1.7.10.4
_______________________________________________
Quagga-dev mailing list
[email protected] <mailto:[email protected]>
https://lists.quagga.net/mailman/listinfo/quagga-dev
_______________________________________________
Quagga-dev mailing list
[email protected]
https://lists.quagga.net/mailman/listinfo/quagga-dev