Lab45. OSPF Virtual Link

ospf-virtuallinkObjective
Mempelajari solusi terhadap area lain yang tidak terhubung langsung ke  area 0. Dimana dalam lab kali ini yang digunakan adalah virtual link

Metode Lab

  • Konfigurasikan OSPF sesuai topologi diatas
  • Area 2 dan Area 3 tidak terhubung Area 0
  • Gunakan Virtual link 1 untuk menghubungkan Area 2 ke Area 0
  • GUnakan Virtual link 2 untuk menghubungkan Area 3 ke Area 0

Verifikasi
Pastikan semua ip loopback yang berasda pada area OSPF yang berbeda bisa saling di ping oleh semua router.

Syarat utama pada OSPF adalah semua area selain area 0 harus tersambung ke Area 0. Untuk itu ada beberapa solusi yang kesemuanya adalah hanya bersifat sementara, tidak boleh dijadikan permanen, yakni

  1. Virtual link
  2. GRE Tunnel

Dan kita akan mulai dari Virtual Link, dalam hal ini akan ada pembuatan 2 virtual link, yakni dari Area 2 ke Area 0, kemudian dilanjutkan dari Area 3 ke Area 0

RM-R1(config)#int lo0
RM-R1(config-if)#ip addr 1.1.1.1 255.255.255.255 
RM-R1(config-if)#int fa0/0
RM-R1(config-if)#no shut
RM-R1(config-if)#ip addr 12.12.12.1 255.255.255.0
RM-R1(config-if)#router ospf 1
RM-R1(config-router)#router-id 1.1.1.1
RM-R1(config-router)#network 1.1.1.1 0.0.0.0 area 0
RM-R1(config-router)#network 12.12.12.1 0.0.0.0 area 1
RM-R2(config)#int lo0
RM-R2(config-if)#ip addr 2.2.2.2 255.255.255.255
RM-R2(config-if)#int fa0/0
RM-R2(config-if)#no shut
RM-R2(config-if)#ip addr 12.12.12.2 255.255.255.0
RM-R2(config-if)#int se0/0
RM-R2(config-if)#no shut 
RM-R2(config-if)#ip addr 23.23.23.2 255.255.255.0
RM-R2(config-if)#router ospf 2
RM-R2(config-router)#router-id 2.2.2.2
RM-R2(config-router)#network 2.2.2.2 0.0.0.0 area 1
RM-R2(config-router)#network 12.12.12.2 0.0.0.0 area 1
RM-R2(config-router)#network 23.23.23.2 0.0.0.0 area 2
RM-R3(config)#int lo0
RM-R3(config-if)#ip addr 3.3.3.3 255.255.255.255
RM-R3(config-if)#int s0/0
RM-R3(config-if)#no shut
RM-R3(config-if)#ip addr 23.23.23.3 255.255.255.0
RM-R3(config-if)#router ospf 3
RM-R3(config-router)#router-id 3.3.3.3
RM-R3(config-router)#network 23.23.23.3 0.0.0.0 area 2
RM-R3(config-router)#network 3.3.3.3 0.0.0.0 area 3

Hasil tanpa ada virtual link maka routing tabelnya tidak lengkap karena adanya beberapa ip loopback yang tidak terdapat pada routing tabelnya.

RM-R1(config-router)#do sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
C       1.1.1.1 is directly connected, Loopback0
     2.0.0.0/32 is subnetted, 1 subnets
O       2.2.2.2 [110/11] via 12.12.12.2, 00:01:03, FastEthernet0/0
     12.0.0.0/24 is subnetted, 1 subnets
C       12.12.12.0 is directly connected, FastEthernet0/0
RM-R1(config-router)#
RM-R2(config-router)#do sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
O IA    1.1.1.1 [110/11] via 12.12.12.1, 00:01:45, FastEthernet0/0
     2.0.0.0/32 is subnetted, 1 subnets
C       2.2.2.2 is directly connected, Loopback0
     23.0.0.0/24 is subnetted, 1 subnets
C       23.23.23.0 is directly connected, Serial0/0
     12.0.0.0/24 is subnetted, 1 subnets
C       12.12.12.0 is directly connected, FastEthernet0/0
RM-R2(config-router)#
RM-R3(config-router)#do sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     3.0.0.0/32 is subnetted, 1 subnets
C       3.3.3.3 is directly connected, Loopback0
     23.0.0.0/24 is subnetted, 1 subnets
C       23.23.23.0 is directly connected, Serial0/0
RM-R3(config-router)#

Pada OSPF, bila diinginkan menggunakan area lain selain area 0, maka area tersebut harus terhubung dengan area 0. Bila ternyata kondisinya ada area yang tidak tersambung dengan area 0, maka hasilnya seperti diatas dimana routing tabelnya tidaklah lengkap karena tidak mau untuk saling berbagi informasi routing tabelnya.

Pada topologi diatas, hanya RM-R1 yang tersambung dengan Area 0. Sedangkan RM-R2 dan RM-R3 tidak, jika kita tampilkan ospf databasenya, maka hanya RM-R1 yang menampilkan informasi tentang Area 0, lainya tidak.

RM-R1(config-router)#do sh ip ospf database

            OSPF Router with ID (1.1.1.1) (Process ID 1)

                Router Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum Link count
1.1.1.1         1.1.1.1         545         0x80000002 0x00D152 1

                Summary Net Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum
2.2.2.2         1.1.1.1         460         0x80000001 0x007DA8
12.12.12.0      1.1.1.1         541         0x80000001 0x001EEC

                Router Link States (Area 1)

Link ID         ADV Router      Age         Seq#       Checksum Link count
1.1.1.1         1.1.1.1         465         0x80000002 0x002EA7 1
2.2.2.2         2.2.2.2         466         0x80000003 0x00A40F 2

                Net Link States (Area 1)

Link ID         ADV Router      Age         Seq#       Checksum
12.12.12.1      1.1.1.1         465         0x80000001 0x004CB8

                Summary Net Link States (Area 1)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         1.1.1.1         554         0x80000001 0x0047EC
RM-R1(config-router)#
RM-R3(config-router)#do sh ip ospf database

            OSPF Router with ID (3.3.3.3) (Process ID 3)

                Router Link States (Area 2)

Link ID         ADV Router      Age         Seq#       Checksum Link count
2.2.2.2         2.2.2.2         555         0x80000003 0x00D425 2
3.3.3.3         3.3.3.3         549         0x80000002 0x00767F 2

                Router Link States (Area 3)

Link ID         ADV Router      Age         Seq#       Checksum Link count
3.3.3.3         3.3.3.3         548         0x80000001 0x007C91 1
RM-R3(config-router)#

Maka berikut kita konfigurasikan virtual linknya pada RM-R2 dan RM-R3, virtual link ini dikonfigurasikan dua sisi, pertama antara RM-R2 dan RM-R1 dulu, berikutnya antara RM-R3 dan RM-R2

Untuk RM-R2 dimana terdapat area 2 didalamnya yang tidak terhubung langsung dengan area 0, maka virtual link dibuat melalui area 1 sebagai jembatanya

RM-R2(config)#router os 2
RM-R2(config-router)#area 1 virtual-link 1.1.1.1

dengan konfigurasi tersebut, kalau kita lihat di RM-R1 akan muncul message seperti berikut

RM-R1(config-router)#
*Mar  1 00:40:56.811: %OSPF-4-ERRRCV: Received invalid packet: mismatch area ID, from backbone area must be virtual-link but not found from 12.12.12.2, FastEthernet0/0

Maka selanjutnya kita konfigurasikan virtual link di sisi RM-R1

RM-R1(config)#router os 1
RM-R1(config-router)#area 1 virtual-link 2.2.2.2
*Mar  1 00:42:56.175: %OSPF-5-ADJCHG: Process 1, Nbr 2.2.2.2 on OSPF_VL0 from LOADING to FULL, Loading Done

Selanjutnya kita cek lagi

RM-R1(config-router)#do sh ip rout
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
C       1.1.1.1 is directly connected, Loopback0
     2.0.0.0/32 is subnetted, 1 subnets
O       2.2.2.2 [110/11] via 12.12.12.2, 00:01:51, FastEthernet0/0
     23.0.0.0/24 is subnetted, 1 subnets
O IA    23.23.23.0 [110/74] via 12.12.12.2, 00:01:51, FastEthernet0/0
     12.0.0.0/24 is subnetted, 1 subnets
C       12.12.12.0 is directly connected, FastEthernet0/0
RM-R1(config-router)#

kita lihat network area 2 yakni 23.23.23.0 sudah masuk ke dalam routing tabe, namun network area 3 tampaknya belum muncul

berikutnya kita konfigurasikan virtual link pada RM-R3 dimana terdapat area 3 didalamnya. untuk terhubung ke area 0, maka area 2 digunakan sebagai jembatanya

RM-R3(config)#router os 3
RM-R3(config-router)#area 2 virtual-link 2.2.2.2

maka pada RM-R2, akan muncul message

RM-R2(config-router)#
*Mar  1 00:53:07.827: %OSPF-4-ERRRCV: Received invalid packet: mismatch area ID, from backbone area must be virtual-link but not found from 23.23.23.3, Serial0/0
RM-R2(config)#router os 2
RM-R2(config-router)#area 2 virtual-link 3.3.3.3
RM-R2(config-router)#
*Mar  1 00:56:15.259: %OSPF-5-ADJCHG: Process 2, Nbr 3.3.3.3 on OSPF_VL1 from LOADING to FULL, Loading Done

kemudian cek routing tabelnya kembali

RM-R1(config-router)#do sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
C       1.1.1.1 is directly connected, Loopback0
     2.0.0.0/32 is subnetted, 1 subnets
O       2.2.2.2 [110/11] via 12.12.12.2, 00:14:48, FastEthernet0/0
     3.0.0.0/32 is subnetted, 1 subnets
O IA    3.3.3.3 [110/75] via 12.12.12.2, 00:01:17, FastEthernet0/0
     23.0.0.0/24 is subnetted, 1 subnets
O IA    23.23.23.0 [110/74] via 12.12.12.2, 00:01:17, FastEthernet0/0
     12.0.0.0/24 is subnetted, 1 subnets
C       12.12.12.0 is directly connected, FastEthernet0/0
RM-R1(config-router)#

kemudian cek routing tabelnya kembali

RM-R1(config-router)#do sh ip route 
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
C       1.1.1.1 is directly connected, Loopback0
     2.0.0.0/32 is subnetted, 1 subnets
O       2.2.2.2 [110/11] via 12.12.12.2, 00:16:40, FastEthernet0/0
     3.0.0.0/32 is subnetted, 1 subnets
O IA    3.3.3.3 [110/75] via 12.12.12.2, 00:03:08, FastEthernet0/0
     23.0.0.0/24 is subnetted, 1 subnets
O IA    23.23.23.0 [110/74] via 12.12.12.2, 00:03:08, FastEthernet0/0
     12.0.0.0/24 is subnetted, 1 subnets
C       12.12.12.0 is directly connected, FastEthernet0/0
RM-R1(config-router)#

kita bisa melihat pada RM-R1 sudah mengenali semua network pada Area 1, Area 2 dan Area 3

RM-R2(config-router)#do sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/11] via 12.12.12.1, 00:07:52, FastEthernet0/0
     2.0.0.0/32 is subnetted, 1 subnets
C       2.2.2.2 is directly connected, Loopback0
     3.0.0.0/32 is subnetted, 1 subnets
O IA    3.3.3.3 [110/65] via 23.23.23.3, 00:07:52, Serial0/0
     23.0.0.0/24 is subnetted, 1 subnets
C       23.23.23.0 is directly connected, Serial0/0
     12.0.0.0/24 is subnetted, 1 subnets
C       12.12.12.0 is directly connected, FastEthernet0/0
RM-R2(config-router)#
RM-R3(config-router)#do sh ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

     1.0.0.0/32 is subnetted, 1 subnets
O       1.1.1.1 [110/75] via 23.23.23.2, 00:08:48, Serial0/0
     2.0.0.0/32 is subnetted, 1 subnets
O IA    2.2.2.2 [110/65] via 23.23.23.2, 00:08:48, Serial0/0
     3.0.0.0/32 is subnetted, 1 subnets
C       3.3.3.3 is directly connected, Loopback0
     23.0.0.0/24 is subnetted, 1 subnets
C       23.23.23.0 is directly connected, Serial0/0
     12.0.0.0/24 is subnetted, 1 subnets
O IA    12.12.12.0 [110/74] via 23.23.23.2, 00:08:48, Serial0/0
RM-R3(config-router)#
RM-R3(config-router)#do ping 1.1.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 60/211/328 ms
RM-R3(config-router)#do ping 2.2.2.2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2.2.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/96/300 ms
RM-R3(config-router)#do ping 3.3.3.3

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 3.3.3.3, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/4 ms
RM-R3(config-router)#
RM-R3(config-router)#do ping 3.3.3.3

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 3.3.3.3, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/4 ms

RM-R3(config-router)#do sh ip ospf virtual-link
Virtual Link OSPF_VL0 to router 2.2.2.2 is up
  Run as demand circuit
  DoNotAge LSA allowed.
  Transit area 2, via interface Serial0/0, Cost of using 64
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:03
    Adjacency State FULL (Hello suppressed)
    Index 1/2, retransmission queue length 0, number of retransmission 0
    First 0x0(0)/0x0(0) Next 0x0(0)/0x0(0)
    Last retransmission scan length is 0, maximum is 0
    Last retransmission scan time is 0 msec, maximum is 0 msec
RM-R3(config-router)#
RM-R2(config-router)#do sh ip ospf virtual
Virtual Link OSPF_VL1 to router 3.3.3.3 is up
  Run as demand circuit
  DoNotAge LSA allowed.
  Transit area 2, via interface Serial0/0, Cost of using 64
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:03
    Adjacency State FULL (Hello suppressed)
    Index 2/4, retransmission queue length 0, number of retransmission 0
    First 0x0(0)/0x0(0) Next 0x0(0)/0x0(0)
    Last retransmission scan length is 0, maximum is 0
    Last retransmission scan time is 0 msec, maximum is 0 msec
Virtual Link OSPF_VL0 to router 1.1.1.1 is up
  Run as demand circuit
  DoNotAge LSA allowed.
  Transit area 1, via interface FastEthernet0/0, Cost of using 10
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:03
    Adjacency State FULL (Hello suppressed)
    Index 1/3, retransmission queue length 0, number of retransmission 1
    First 0x0(0)/0x0(0) Next 0x0(0)/0x0(0)
    Last retransmission scan length is 1, maximum is 1
    Last retransmission scan time is 0 msec, maximum is 0 msec
RM-R2(config-router)#
RM-R1(config-router)#do sh ip os vi
Virtual Link OSPF_VL0 to router 2.2.2.2 is up
  Run as demand circuit
  DoNotAge LSA allowed.
  Transit area 1, via interface FastEthernet0/0, Cost of using 10
  Transmit Delay is 1 sec, State POINT_TO_POINT,
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    Hello due in 00:00:05
    Adjacency State FULL (Hello suppressed)
    Index 1/2, retransmission queue length 0, number of retransmission 0
    First 0x0(0)/0x0(0) Next 0x0(0)/0x0(0)
    Last retransmission scan length is 0, maximum is 0
    Last retransmission scan time is 0 msec, maximum is 0 msec
RM-R1(config-router)#
RM-R1(config-router)#do sh ip rout
 Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
 D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
 N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
 E1 - OSPF external type 1, E2 - OSPF external type 2
 i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
 ia - IS-IS inter area, * - candidate default, U - per-user static route
 o - ODR, P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/32 is subnetted, 1 subnets
 C       1.1.1.1 is directly connected, Loopback0
 2.0.0.0/32 is subnetted, 1 subnets
 O       2.2.2.2 [110/11] via 12.12.12.2, 00:01:51, FastEthernet0/0
 23.0.0.0/24 is subnetted, 1 subnets
 O IA    23.23.23.0 [110/74] via 12.12.12.2, 00:01:51, FastEthernet0/0
 12.0.0.0/24 is subnetted, 1 subnets
 C       12.12.12.0 is directly connected, FastEthernet0/0
 RM-R1(config-router)#

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.