OSPF Virtual Links to Interconnect Backbone Areas on Huawei Routers

OSPF Virtual Links to Interconnect Backbone Areas on Huawei Routers

What are OSPF Virtual Links?

When designing an OSPF network, it is a requirement that all OSPF areas should be connected to the backbone area 0. In some implementations, it’s impossible to have a physical connection from a remote area to area 0. An OSPF virtual link can be applied in two scenarios.

  1. To connect the remote area to the backbone through a non-backbone area.
  2.  Virtual links can also be used to connect two parts of a partitioned backbone through a non-backbone area.

Note: The area through which you configure the virtual link, known as a transit area, must have full routing information, hence the transit area cannot be a stub area.

Lab setup and Configuration Steps: In this article, we focus on the second application of virtual links. The Objective is to connect the two backbone areas using OSPF virtual links.

Step 1: Configure system names and IP addresses on all the routers.

Its Best practice to configure interface description and router ID on your network. The router ID should be configured as Loopback 0 and is used to identify the routers in OSPF adjacencies.

*****************************************R1
sys
#
sysname R1
#
router id 1.1.1.1
#
interface Loopback0
ip address 1.1.1.1 32
#
interface Ethernet 0/0/0
description TO_R2_ETH/0/01
ip address 10.10.10.0 31
#
#
interface Ethernet 0/0/1
description TO_R9_ETH/0/0/0
ip address 10.10.10.14 31
#
commit
*****************************************R2
sys
#
sysname R2
#
router id 2.2.2.2
#
interface Loopback0
ip address 2.2.2.2 32
#
interface Ethernet 0/0/1
description TO_R1_ETH/0/0/0
ip address 10.10.10.1 31
#
interface Ethernet 0/0/0
description TO_R1_ETH/0/0/0
ip address 10.10.10.2 31
#
commit
*****************************************R3
sys
#
sysname R3
#
router id 3.3.3.3
#
interface Loopback0
ip address 3.3.3.3 32
#
interface Ethernet 0/0/0
description TO_R4_ETH/0/0/0
ip address 10.10.10.4 31
#
interface Ethernet 0/0/1
description TO_R2_ETH/0/0/0
ip address 10.10.10.3 31
#
commit
*****************************************R4
sys
#
sysname R4
#
router id 4.4.4.4
#
interface Loopback0
ip address 4.4.4.4 32
#
interface Ethernet 0/0/0
description TO_R5_ETH/0/0/1
ip address 10.10.10.6 31
#
interface Ethernet 0/0/1
description TO_R3_ETH/0/0/0
ip address 10.10.10.5 31
#
commit
*****************************************R5
sys
#
sysname R5
#
router id 5.5.5.5
#
interface Loopback0
ip address 5.5.5.5 32
#
interface Ethernet 0/0/0
description TO_R6_ETH/0/0/1
ip address 10.10.10.8 31
#
interface Ethernet 0/0/1
description TO_R4_ETH/0/0/0
ip address 10.10.10.7 31
#
commit
*****************************************R6
sys
#
sysname R6
#
router id 6.6.6.6
#
interface Loopback0
ip address 6.6.6.6 32
#
interface Ethernet 0/0/0
description TO_R7_ETH/0/0/1
ip address 10.10.10.10 31
#
interface Ethernet 0/0/1
description TO_R5_ETH/0/0/0
ip address 10.10.10.9 31
#
commit
*****************************************R7
sys
#
sysname R7
#
router id 7.7.7.7
#
interface Loopback0
ip address 7.7.7.7 32
#
interface Ethernet 0/0/0
description TO_R6_ETH/0/0/0
ip address 10.10.10.11 31
#
#
interface Ethernet 0/0/1
description TO_R8_ETH/0/0/0
ip address 10.10.10.14 31
#
commit
*****************************************R8
sys
#
sysname R8
#
router id 8.8.8.8
#
interface Loopback0
ip address 8.8.8.8 32
#
interface Ethernet 0/0/0
description TO_R7_ETH/0/0/1
ip address 10.10.10.13 31
#
commit
*****************************************R9
sys
#
sysname R9
#
router id 9.9.9.9
#
interface Loopback0
ip address 9.9.9.9 32
#
interface Ethernet 0/0/1
description TO_R1_ETH/0/0/1
ip address 10.10.10.15 31
#
commit

Step 2: Configure OSPF on all the routers and advertise the networks in respective areas.

*************************************R1
#
ospf 10 router-id 1.1.1.1
 area 0.0.0.0
  network 1.1.1.1 0.0.0.0
  network 10.10.10.0 0.0.0.1
  network 10.10.10.2 0.0.0.1
  network 3.3.3.2 0.0.0.1
#
commit
************************************R2
#
ospf 10
 area 0.0.0.0
  network 10.10.10.0 0.0.0.1
  network 10.10.10.2 0.0.0.1
  network 2.2.2.2 0.0.0.0
#
************************************R3
#
ospf 10
 area 0.0.0.0
  network 10.10.10.2 0.0.0.1
  network 3.3.3.3 0.0.0.0
 area 0.0.0.1
  network 10.10.10.4 0.0.0.1
#
commit


************************************R4
#
ospf 10
 area 0.0.0.1
  network 4.4.4.4 0.0.0.0
  network 10.10.10.4 0.0.0.1
  network 10.10.10.6 0.0.0.1
#
commit
************************************R5
#
ospf 10
 area 0.0.0.1
  network 5.5.5.4 0.0.0.1
  network 10.10.10.6 0.0.0.1
 area 0.0.0.2
  network 10.10.10.8 0.0.0.1
#
************************************R6
#
ospf 10
 area 0.0.0.2
  network 6.6.6.6 0.0.0.0
  network 10.10.10.8 0.0.0.1
  network 10.10.10.10 0.0.0.1
#
commit
************************************R7
#
ospf 10
 area 0.0.0.2
  network 7.7.7.7 0.0.0.0
  network 10.10.10.10 0.0.0.1
#
commit
************************************R8
#
ospf 10
 area 0.0.0.3
  network 8.8.8.8 0.0.0.0
  network 10.10.10.12 0.0.0.1
#
commit
************************************R9
#
ospf 10
 area 0.0.0.4
  network 9.9.9.9 0.0.0.0
  network 10.10.10.14 0.0.0.1
#
commit

Step 3: Check OSPF adjacency status and routing tables on all the routers.

R8 has routes from Area 0(1) and Area 1 but doesn’t have routes from Area 0(2) and Area 4
R9 has OSPF routes from Area 0(2) and Area 1, but doesnt have routes from Area 0(1) and Area 3

Step 4: Configure OSPF Virtual Links on R5 and R3. Area 1 is our transit area.

************************************R3
#
ospf 10
 area 0.0.0.1
  vlink-peer 5.5.5.5
#
commit
************************************R5
#
ospf 10
 area 0.0.0.1
  vlink-peer 3.3.3.3
#
commit

Step 5: Verify OSPF virtual link status between R3 and R5 using the command “dispay ospf vlink”. Recheck the routing table of R1 and R6. We are now able to exchange the routing information over the virtual link.

Virtual Link status is Okay. Shows Area 1 is our transit area.
R9 has routes from all the areas after implementing Virtual Link.
R8 has the routes from all areas and we are able to ping R9 Loopback 0.


Leave a Reply

This website uses cookies and asks your personal data to enhance your browsing experience.