In this document, I am going to present why the Forward Address is necessary in redistribution of external routes. OSPF always has fun with us. Lets have some fun with OSPF.
Prerequisite: Knowledge of NSSA in OSPF
I am using the following scenario for this presentation. The last octet of the transit IP addresses are the router IDs. For example, the IP address on R2 would be 22.214.171.124. I had to skip some prerequisites since it could be a very long document as it kind of is.
126.96.36.199 has been redistributed in to OSPF. Lets see OSPF database for 188.8.131.52 on R5.
The Forward Address is 172.16.1.1 which is the IP address of R1 loopback interface. OSPF first chooses a loopback interface for Forward Address. If loopback is not present, a physical IP address will be selected. Please refer to Cisco website for more information about Forward Address selection.
ASBR in NSSA area advertises the external routes through LSA 7. ABR translates LSA 7 to LSA 5. It is important to know that only one ABR does the translation. ABR with higher router ID wins the election. ABR replaces its own RID in LSA 5. We see later in this document that some part of metric will be lost because of this translation.
Forward Address is very important. OSPF uses Forward Address to determine the best path and metric. Lets see the routing table of R5.
Metric for 172.16.1.1 is 4. OSPF metric for redistribution is 20 (except from BGP) so the total metric for 184.108.40.206 is 24. Lets prove that OSPF is using Foward Address to calculate metric for external routes. I am going to change the loopback interface cost on R1 to 1000.
Now, you can see the metric for external address is increased to 1023.
I changed the costs to default. Lets see the routing table of R4 for 220.127.116.11 and 172.16.1.1. R4 load balances across R2 and R3 for both when Forward Address is present and Forward Address is a loopback address. (The behavior is different when the Forward Address is not loopback if ASBR has more than one physical interface in OSPF)
There are two equal paths to 18.104.22.168 as there are for 172.16.1.1. Lets suppress Forward Address.
On ABR, you can suppress the Forward Address with the following command.
Lets see OSPF database for external address of 22.214.171.124 on R5. As you see, it changed to all 0.
Now, OSPF in area 2 is depending on LSA type 4 to determine the best path path and metric to 126.96.36.199. I am not going to explain how because this document is long enough. I will post another document later. Since ABR is translating LSA type 7 to type 5, metric from ABR to ASBR is lost. It may cause sub optimal routing. Also R2 sends all the packets to the ABR which is translates the LSA 7 to LSA 5.
Lets see the metric after Forward Address suppression. You only see metric from R5 to R3. Metric from R3 to R1 is lost. (metric is 22)
Lets change OSPF costs on all R3 interfaces to 1000
Check the metric again on R5. Metric of loopback interface has been changed but still metric of 188.8.131.52 is 22
Lets check traceroute from R5 to 184.108.40.206. R4 could send the packets to R2 since it is a better path, but still forwards them to R3(220.127.116.11). This is sub-optimal routing because I changed the costs of R3 interfaces to 1000.
Lets have more fun and cause loop. The costs of all the interfaces are 1 now except interface from R3 to R1 has the cost of 1000. It means now the path from R3 to R2 to R1 is better than R3 to R1. But lets see the routing table of R2. R2 points back to R3 for 18.104.22.168
What is the reason? R2 receives type 7 routes from R1 and also type 5 route from R3 after translation. Which one is preferred? Of course, type 5 is preferred.
R3 forwards the packet to R2 and R2 returns them back.
Avoids suppressing Forward Address unless you only want one ABR to forward the traffic.
If there are two ABRs, use two interfaces to connect them. ( In later documents, I will explain why)
Use loopback address for Forward Address if ASBR has several interfaces in OSPF domain. Using physical address prevents load balancing and cause sub optimal routing. In my scenario, use 22.214.171.124 on R1 as a Forward Address and see the result based on the metric to see why using loopback is important.
In short, OSPF uses Forward Address to calculate metric and perform optional routing.
Please rate if it is beneficial for you. Wish you the best.
i can't ping from Admin to R1 or R2 or any of the endpoints connected to R1 but i am able to ping R3 from admin and then am able to ping the endpoints of R1 from the cli of R3 any ideas on what the issue is
Hello, I have a network composed of approximately 100 switches that uses the MST protocol as an antiloop protocol. The CORE switch is the root bridge of the network and has priority 24576.To eliminate the risk of inserting a switch in the networ...
My setup is two cEdges running VRRP. In my scenario,cEdge01 is Master and has two ISPs connected to it. cEdge02 is Standby and has one ISP connected to it. Each TLOC-X has it's one cable, so three cables connecting between the cEdges. All vManaged. OkSo T...
At one of our sites we have our own router Cisco 1941 router connected to an ISP router also Cisco as happens I can remote onto our 1941 router using its wan IP no issues there But when I connect through our management loop back address I am get...
Hi All,I have a scenario A Cisco 2900 Router connected to InternetA Catalyst Core Switch configured with all VLANsAccess Switches connected to End devices Now the client machines are configured with Local DNS (the DC Address), DNS for Internet.&...