Remember OLD DR
Introduction – Preemption vs Remember OLD DR
Remembering old DR is an optimization of DR/BDR election process. It’s a Cisco proprietary and use to enable fast DR recovery in a multi-access network.
Preemption – In a situation where multiple router are declaring themselves a DR or BDR, OSPF override the non-preemptive behavior of DR/BDR election process ( upholding it would prevent the router from arriving a single DR/BDR) and the contending routers enter the election phase again. But with this RFC defined( RFC2328 ) method, the election process further inherits some unnecessary delay.
Remember OLD DR – It is a optimization technique to further reduce the delay and provide a smoother and graceful transition of the DR from a partitioned multi-access network to a integrated one. Please refer to the below diagram to have a proper understanding.
Multi-access Partitioning and behavior of OSPF DR/BDR Election
Below diagram explains a multi-access network where 4 routers are connected with 2 interlink switch. At the beginning when the interlink was up, R4 was the DR and R3 was the BDR according to their router id. Once the interlink between two switches are turned off, this single multi-access will be partitioned into two isolated multi-access network(e.g lower multi-access and upper multi-access). Now clearly with the standard DR/BDR election, R4 becomes DR of the upper multi-access and R3 becomes the DR of the lower multi-access. One interesting feature we will be discussing further when the interlink between two switches will again comes up within a certain interval of time. Upon the interlink connected again, the OLD DR(R4) will be immediately become the DR of the whole multi-access network and a election for a new BDR will take place.
Before Partitioned R1#show ip ospf nei Neighbor ID Pri State Dead Time Address Interface 188.8.131.52 1 2WAY/DROTHER 00:00:30 10.0.0.2 Ethernet0/0 184.108.40.206 1 FULL/BDR 00:00:32 10.0.0.3 Ethernet0/0 220.127.116.11 1 FULL/DR 00:00:32 10.0.0.4 Ethernet0/0 R1#
After Partitioned R1#show ip ospf nei Neighbor ID Pri State Dead Time Address Interface 18.104.22.168 1 FULL/DR 00:00:36 10.0.0.4 Ethernet0/0 R1# R2#show ip ospf nei Neighbor ID Pri State Dead Time Address Interface 22.214.171.124 1 FULL/DR 00:00:38 10.0.0.3 Ethernet0/0 R2#
After the Interlink comes back and the multi-access integration takes place R1#show ip ospf nei Neighbor ID Pri State Dead Time Address Interface 126.96.36.199 1 FULL/BDR 00:00:31 10.0.0.2 Ethernet0/0 188.8.131.52 1 2WAY/DROTHER 00:00:39 10.0.0.3 Ethernet0/0 184.108.40.206 1 FULL/DR 00:00:31 10.0.0.4 Ethernet0/0 R1#
Keep the old Type-2 LAS into the database of new elected DR
- The routers will remember who the old DR was because its ID is the Advertising Router ID of its old LSA-2 they want to gracefully migrate from.
- During a transition period of 3 minutes, routers will advertise two links to transit networks in their own LSA-1, both the link to the old LSA-2 and the link to the new LSA-2. Old DRs will not flush their old LSA-2 during this transition period.
- After the transition period has passed, old DRs will flush their LSA-2, upon which the remaining routers will forget about the old DR and refresh their LSA-1, this time pointing only to the new LSA-2 originated by the new DR.
The above steps simply indicates that the routers in a partitioned multi-access network will keep the old LSA-2 received from it’s old DR for a period of 3 minutes. And in case the old DR comes back during that transition time, the contending routers will accept that by just looking at their old LSA-2.
|OSPF Database before partitioning||OSPF Database after partitioning|
Delete Flag & Routing Bit Set
Example of Router R3 showing the results of it’s Type-2 LSA in it’s database after final integration when the interlink comes back. We can see a delete flag is set for the old LSA-2 and Routing-bit is set for the current LSA-2. After the transition period of 3 minutes, the old LSA-2 will be removed.
|Results after final integration when the interlink comes back.|
R3#show ip ospf data network
OSPF Router with ID (220.127.116.11) (Process ID 1) Net Link States (Area 0)Delete flag is set for this LSA LS age: MAXAGE(3601) Options: (No TOS-capability, DC) LS Type: Network Links Link State ID: 10.0.0.2 (address of Designated Router) Advertising Router: 18.104.22.168 LS Seq Number: 80000003 Checksum: 0xA36C Length: 32 Network Mask: /24 Attached Router: 22.214.171.124 Attached Router: 126.96.36.199 Routing Bit Set on this LSA in topology Base with MTID 0 LS age: 179 Options: (No TOS-capability, DC) LS Type: Network Links Link State ID: 10.0.0.4 (address of Designated Router) Advertising Router: 188.8.131.52 LS Seq Number: 80000009 Checksum: 0xB231 Length: 40 Network Mask: /24 Attached Router: 184.108.40.206 Attached Router: 220.127.116.11 Attached Router: 18.104.22.168 Attached Router: 22.214.171.124 R3# **************** After 3 minutes **************** R3#show ip ospf database
Net Link States (Area 0)Link ID ADV Router Age Seq# Checksum 10.0.0.4 126.96.36.199 568 0x80000009 0x00B231 R3#