ospfd: Remember network LSA sequence numbers across up/downs of an interface
* ospf_interface.h: (struct ospf_if_params) add field for saved network LSA
seqnum
* ospf_interfa.c: (ospf_new_if_params) init network_lsa_seqnum field to
initial seqnum - doesnt matter though.
* ospf_lsa.c: (ospf_network_lsa_new) check for any saved sequence number,
and use if it exists. Save the result back. This should help avoid needless
round of LSUpdate/LSRequests when a neighbour has to tell the originator
"uhm, i have something newer than that already".
* ospf_vty.c: (show_ip_ospf_interface_sub) Show the saved network LSA seqnum
diff --git a/ospfd/ospf_vty.c b/ospfd/ospf_vty.c
index adc822a..4e52a11 100644
--- a/ospfd/ospf_vty.c
+++ b/ospfd/ospf_vty.c
@@ -2933,7 +2933,13 @@
inet_ntoa (nbr->address.u.prefix4), VTY_NEWLINE);
}
}
-
+
+ /* Next network-LSA sequence number we'll use, if we're elected DR */
+ if (oi->params && ntohl (oi->params->network_lsa_seqnum)
+ != OSPF_INITIAL_SEQUENCE_NUMBER)
+ vty_out (vty, " Saved Network-LSA sequence number 0x%x%s",
+ ntohl (oi->params->network_lsa_seqnum), VTY_NEWLINE);
+
vty_out (vty, " Multicast group memberships:");
if (OI_MEMBER_CHECK(oi, MEMBER_ALLROUTERS)
|| OI_MEMBER_CHECK(oi, MEMBER_DROUTERS))