I found a strange behavior in cisco OSPF spf calculcation and routing bit positionning :
Consider this design : LAN1(Area0)---- ASBR1 -------- IP Tunnel1 (Area0)---- ASBR3 --(Area0)--- LAN2 -- FW | | | | ------(Area0)--- ASBR2 ---------- IP Tunnel2 (Area0)---- ASBR4 ----(Area0)----- ASBR3 & 4 (attached to LAN2) redistribute one static route pointing to the FW as External 2. the FW is NOT running OSPF. Each ASBR has his LAN interface running OSPF in Area 0 (wildcard is 0.0.0.0, so forwarding address of redistributed routes is 0.0.0.0 and not the FW). The IP tunnel interfaces are in area 0 too. The tunnel 1 has a cost of 100 The tunnel 2 has a cost of 200 On ASBR1 I can see two type 5 LSA (all captures are from ASBR1) : one for each ASBR. And one route in the routing table (best forwarding metric). All is good for the moment ! NB : I can reproduce this behavior with type 3 LSA. BUT, I can see in the database that the two LSAs have the routing bit set !! Router#sh ip ospf data external OSPF Router with ID (200.0.0.3) (Process ID 1) Type-5 AS External Link States Routing Bit Set on this LSA LS age: 1274 Options: (No TOS-capability, DC) LS Type: AS External Link Link State ID: 192.0.0.1 (External Network Number ) Advertising Router: 200.0.0.1 LS Seq Number: 80000002 Checksum: 0xFC17 Length: 36 Network Mask: /32 Metric Type: 2 (Larger than any link state path) TOS: 0 Metric: 20 Forward Address: 0.0.0.0 External Route Tag: 0 Routing Bit Set on this LSA LS age: 1041 Options: (No TOS-capability, DC) LS Type: AS External Link Link State ID: 192.0.0.1 (External Network Number ) Advertising Router: 200.0.0.4 LS Seq Number: 80000007 Checksum: 0xE02B Length: 36 Network Mask: /32 Metric Type: 2 (Larger than any link state path) TOS: 0 Metric: 20 Forward Address: 0.0.0.0 External Route Tag: 0 If I debug, I can see that, the first LSA is analyzed, there's no route in routing table, so the LSA is putted in RT (routing bit set for the LSA). Then, the second LSA is analyzed (better fwd metric), the metric is changed in routing table (because NH is the same). and routing bit is set on the second LSA. The problem is that the routing bit is not reset on the first LSA, because the metric was just changed (route was not deleted). 03:10:04: OSPF: Started Building Type 5 External Routes 03:10:04: OSPF: Start processing Type 5 External LSA 192.0.0.1, mask 255.255.255 .255, adv 200.0.0.1, age 696, seq 0x80000002, metric 20, metric-type 2 03:10:04: Add better path to LSA ID 192.0.0.1, gateway 22.0.0.1, dist 20 03:10:04: Add path: next-hop 22.0.0.1, interface Tunnel0 03:10:04: network update dest_addr 192.0.0.1 mask 255.255.255.255 gateway 22.0. 0.1 03:10:04: RT: add 192.0.0.1/32 via 22.0.0.1, ospf metric [110/20] 03:10:04: Add External Route to 192.0.0.1. Metric: 20, Next Hop: 22.0.0.1 03:10:04: OSPF: insert route list LS ID 192.0.0.1, type 5, adv rtr 200.0.0.1 03:10:04: OSPF: Start processing Type 5 External LSA 192.0.0.1, mask 255.255.255 .255, adv 200.0.0.4, age 463, seq 0x80000007, metric 20, metric-type 2 03:10:04: Add better path to LSA ID 192.0.0.1, gateway 22.0.0.1, dist 20 03:10:04: Add path: next-hop 22.0.0.1, interface Tunnel0 03:10:04: network update dest_addr 192.0.0.1 mask 255.255.255.255 gateway 22.0. 0.1 03:10:04: RT: metric change to 192.0.0.1 via 22.0.0.1, ospf metric [110/20] new metric [110/20] 03:10:04: Add External Route to 192.0.0.1. Metric: 20, Next Hop: 22.0.0.1 03:10:04: OSPF: insert route list LS ID 192.0.0.1, type 5, adv rtr 200.0.0.4 03:10:04: OSPF: ex_delete_old_routes 03:10:04: OSPF: Started Building Type 7 External Routes 03:10:04: OSPF: ex_delete_old_routes To follow my meaning, I modify the router-id from ASBR4 200.0.0.1 to 200.0.0.10 (same LSA just changed router-id of the ASBR). With this, the first LSA become the last in cisco LSA processing. After clear ip ospf process (ASBR1 always), I can see this debug : 03:32:37: OSPF: Started Building Type 5 External Routes 03:32:37: OSPF: Start processing Type 5 External LSA 192.0.0.1, mask 255.255.255 .255, adv 200.0.0.4, age 691, seq 0x80000009, metric 20, metric-type 2 03:32:37: Add better path to LSA ID 192.0.0.1, gateway 22.0.0.1, dist 20 03:32:37: Add path: next-hop 22.0.0.1, interface Tunnel0 03:32:37: network update dest_addr 192.0.0.1 mask 255.255.255.255 gateway 22.0. 0.1 03:32:37: RT: add 192.0.0.1/32 via 22.0.0.1, ospf metric [110/20] 03:32:37: Add External Route to 192.0.0.1. Metric: 20, Next Hop: 22.0.0.1 03:32:37: OSPF: insert route list LS ID 192.0.0.1, type 5, adv rtr 200.0.0.4 03:32:37: OSPF: Start processing Type 5 External LSA 192.0.0.1, mask 255.255.255 .255, adv 200.0.0.10, age 500, seq 0x80000001, metric 20, metric-type 2 03:32:37: OSPF: higher forward cost The first LSA is inserted in routing table (because of no route at the beginning), the second LSA is analyzed and no change beacuse of higher fwding cost. So in the database, just one LSA with routing bit set. Router#sh ip ospf data ext OSPF Router with ID (200.0.0.3) (Process ID 1) Type-5 AS External Link States Routing Bit Set on this LSA LS age: 588 Options: (No TOS-capability, DC) LS Type: AS External Link Link State ID: 192.0.0.1 (External Network Number ) Advertising Router: 200.0.0.4 LS Seq Number: 80000009 Checksum: 0xDC2D Length: 36 Network Mask: /32 Metric Type: 2 (Larger than any link state path) TOS: 0 Metric: 20 Forward Address: 0.0.0.0 External Route Tag: 0 LS age: 398 Options: (No TOS-capability, DC) LS Type: AS External Link Link State ID: 192.0.0.1 (External Network Number ) Advertising Router: 200.0.0.10 LS Seq Number: 80000001 Checksum: 0xC843 Length: 36 Network Mask: /32 Metric Type: 2 (Larger than any link state path) TOS: 0 Metric: 20 Forward Address: 0.0.0.0 External Route Tag: 0 At this moment, I can deduce that my "routing bit problem" seems to depend of processing order of the LSAs. To view the problem, in more depth, I change the tunnel cost, tunnel2 has now a cost of 101. before this modification , ASBR1 used ASBR3 for joining ASBR3 & 4. Now, ASBR1 join ASBR3 by ASBR3 (tunnel) and ASBR4 by the ASBR2 (LAN1) because of lower cost. I change back the router-id of ASBR4 from 200.0.0.10 to 200.0.0.1 (situation with the two routing bit set). Now if I clear the OSPF process, I see : 05:39:49: OSPF: Started Building Type 5 External Routes 05:39:49: OSPF: Start processing Type 5 External LSA 192.0.0.1, mask 255.255.255 .255, adv 200.0.0.1, age 1871, seq 0x8000000D, metric 20, metric-type 2 05:39:49: Add better path to LSA ID 192.0.0.1, gateway 173.0.0.1, dist 20 05:39:49: Add path: next-hop 173.0.0.1, interface FastEthernet0 05:39:49: network update dest_addr 192.0.0.1 mask 255.255.255.255 gateway 173.0 .0.1 05:39:49: RT: add 192.0.0.1/32 via 173.0.0.1, ospf metric [110/20] 05:39:49: Add External Route to 192.0.0.1. Metric: 20, Next Hop: 173.0.0.1 05:39:49: OSPF: insert route list LS ID 192.0.0.1, type 5, adv rtr 200.0.0.1 05:39:49: OSPF: Start processing Type 5 External LSA 192.0.0.1, mask 255.255.255 .255, adv 200.0.0.4, age 429, seq 0x8000000D, metric 20, metric-type 2 05:39:49: Add better path to LSA ID 192.0.0.1, gateway 22.0.0.1, dist 20 05:39:49: Add path: next-hop 22.0.0.1, interface Tunnel0 05:39:49: network update dest_addr 192.0.0.1 mask 255.255.255.255 gateway 22.0. 0.1 05:39:49: RT: del 192.0.0.1/32 via 173.0.0.1, ospf metric [110/20] 05:39:49: RT: add 192.0.0.1/32 via 22.0.0.1, ospf metric [110/20] 05:39:49: Add External Route to 192.0.0.1. Metric: 20, Next Hop: 22.0.0.1 The two LSAs have the routing bit set ... : Router#sh ip ospf data ext OSPF Router with ID (200.0.0.3) (Process ID 1) Type-5 AS External Link States Routing Bit Set on this LSA LS age: 1904 Options: (No TOS-capability, DC) LS Type: AS External Link Link State ID: 192.0.0.1 (External Network Number ) Advertising Router: 200.0.0.1 LS Seq Number: 8000000D Checksum: 0xE622 Length: 36 Network Mask: /32 Metric Type: 2 (Larger than any link state path) TOS: 0 Metric: 20 Forward Address: 0.0.0.0 External Route Tag: 0 Routing Bit Set on this LSA LS age: 462 Options: (No TOS-capability, DC) LS Type: AS External Link Link State ID: 192.0.0.1 (External Network Number ) Advertising Router: 200.0.0.4 LS Seq Number: 8000000D Checksum: 0xD431 Length: 36 Network Mask: /32 Metric Type: 2 (Larger than any link state path) TOS: 0 Metric: 20 Forward Address: 0.0.0.0 External Route Tag: 0 Does anyone can explain me ??? Message Posted at: http://www.groupstudy.com/form/read.php?f=7&i=54235&t=54235 -------------------------------------------------- FAQ, list archives, and subscription info: http://www.groupstudy.com/list/cisco.html Report misconduct and Nondisclosure violations to [EMAIL PROTECTED]