OSPFv3 Graceful Restart
Extracted elements (14)
OSPFv3 does not require the router-address TLV used in OSPFv2 graceful restart because in OSPFv3, neighboring routers on any link are always identified by their Router IDs, whereas OSPFv2 uses IPv4 interface addresses for neighbors on broadcast, NBMA, and point-to-multipoint links.
Placing the burden on the restarting router to preserve Interface IDs across restarts (rather than synchronizing Interface ID changes between neighbors) was chosen because it provides a more robust, more deterministic, and simpler mechanism.
Many implementations use the interface's MIB-II IfIndex for Interface ID. The persistence of Interface ID across reboots is described in section 3.1.5 of RFC 2863 (The Interfaces Group MIB).
The Grace Period TLV (Type=1, Length=4) MUST always appear in a grace-LSA.
The Graceful Restart Reason TLV (Type=2, Length=1) MUST always appear in a grace-LSA.
The OSPFv3 Interface ID MUST be preserved by the restarting router across restarts, because changes in the Interface ID during graceful restart will cause a mismatch between pre-restart LSAs and neighbor adjacency state, terminating the graceful restart prematurely.
To avoid network churn during graceful restart, the restarting router MUST preserve the LSA ID to prefix correspondence across graceful restarts, since OSPFv3 inter-area prefix LSA and external LSA IDs are unsigned 32-bit integers without a direct prefix correspondence.
A grace-LSA in OSPFv3 is defined as an LSA with LS type equal to 0x000b, LSA function code 11, with S2-bit and S1-bit set to 0 to indicate link-local flooding scope, and U-bit set to 0.
The Grace Period TLV (Type=1, Length=4) encodes the number of seconds that the router's neighbors should continue to advertise the router as fully adjacent regardless of database synchronization state. This TLV MUST always appear in a grace-LSA.
The Graceful Restart Reason TLV (Type=2, Length=1) encodes the reason for the router restart: 0 (unknown), 1 (software restart), 2 (software reload/upgrade), or 3 (switch to redundant control processor). This TLV MUST always appear in a grace-LSA.
A new LSA function code 11 (LS type 0x000b) for the OSPFv3 grace-LSA has been assigned in the 'OSPFv3 LSA Function Codes' sub-registry of the 'Open Shortest Path First v3 (OSPFv3) Parameters' registry. Grace-LSA TLVs reuse the 'OSPFv2 Grace LSA Top Level TLV' IANA sub-registry.
OSPFv3-AUTH relies on manual key distribution which precludes replay protection using sequence numbers. Replaying an OSPF Link-Update containing a grace-LSA could deceive neighbors into believing a decommissioned router is undergoing graceful restart, but this attack is harder than replaying hello packets and does not raise new security concerns beyond those in RFC 2740, RFC 4552, and RFC 3623.
Each TLV in the grace-LSA is encoded as a 2-octet Type field, 2-octet Length field, and variable-length Value field, formatted according to section 2.3.2 of RFC 3630 (OSPF-TE).
The Grace-LSA format contains a standard OSPFv3 LSA header (LS age, LS type 0x000b, Link State ID, Advertising Router, LS sequence number, LS checksum, Length) followed by TLVs. The Link State ID is the Interface ID of the interface originating the LSA.