OSPF Lab1 – Configuring OSPF in NBMA

Ensurepass

objectives

1. Learn the two configuration method of manual and auto setup of neighbor relations in network

2. Learn how to specify OSPF interface priority, and how to avoid DR selection error by changing OSPF default interface network type.
Lab Topology

6-1

Lab steps and requirements

1. Configure IP addresses of every router, and use ping command to confirm the direct interface connectivity of every router.

2. The following shows configurations of R1, R2 and R3:

R1(config)#interface loopback 0

R1(config-if)#ip address 172.16.1.1 255.255.255.0

R1(config-if)#ip ospf network point-to-point

R1(config-if)#exit

R1(config)#

R1(config)#interface serial 1/2

R1(config-if)#ip add 192.168.1.1 255.255.255.0

R1(config-if)#encapsulation frame-relay

R1(config-if)#no frame-relay inverse-arp

R1(config-if)#frame-relay map ip 192.168.1.2 102 broadcast

R1(config-if)#frame-relay map ip 192.168.1.3 103 broadcast

R1(config-if)#exit

R1(config)#

R1(config)#router ospf 1

R1(config-router)#network 192.168.1.0 0.0.0.255 area 0

R1(config-router)#network 172.16.1.0 0.0.0.255 area 0

R1(config-router)#exit

R1(config)#

R2(config)#interface loopback 0

R2(config-if)#ip address 172.16.3.1 255.255.255.0

R2(config-if)#ip ospf network point-to-point

R2(config-if)#exit

R2(config)#

R2(config)#interface serial 1/2

R2(config-if)#encapsulation frame-relay

R2(config-if)#ip address 192.168.1.2 255.255.255.0

R2(config-if)#no frame-relay inverse-arp

R2(config-if)#frame-relay map ip 192.168.1.1 201 broadcast

R2(config-if)#no shutdown

R2(config-if)#exit

R2(config)#

R2(config)#router ospf 1

R2(config-router)#network 172.16.3.0 0.0.0.255 area 0

R2(config-router)#network 192.168.1.0 0.0.0.255 area 0

R2(config-router)#exit

R2(config)#

R3(config)#interface loopback 0

R3(config-if)#ip address 172.16.4.1 255.255.255.0

R3(config-if)#ip ospf network point-to-point

R3(config-if)#exit

R3(config)#

R3(config)#interface serial 1/2

R3(config-if)#ip address 192.168.1.3 255.255.255.0

R3(config-if)#encapsulation frame-relay

R3(config-if)#no frame-relay inverse-arp

R3(config-if)#frame-relay map ip 192.168.1.1 301 broadcast

R3(config-if)#no shutdown

R3(config-if)#exit

R3(config)#

R3(config)#router ospf 1

R3(config-router)#network 172.16.4.0 0.0.0.255 area 0

R3(config-router)#network 192.168.1.0 0.0.0.255 area 0

R3(config-router)#exit

R3(config)#

3. After configuring OSPF, check OSPF neighbor table of R1, R2 and R3, and find that OSPF neighbor relation has not been set up.

R1#show ip ospf neighbor

R1#

4. Check OSPF information of Serial 1/2 on R1.

R1#show ip ospf interface serial 1/2

Serial1/2 is up, line protocol is up

Internet Address 192.168.1.1/24, Area 0

Process ID 1, Router ID 172.16.1.1, Network Type NON_BROADCAST, Cost: 64

Transmit Delay is 1 sec, State DR, Priority 1

Designated Router (ID) 172.16.1.1, Interface address 192.168.1.1

No backup designated router on this network

Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5

oob-resync timeout 120

Hello due in 00:00:15

Index 1/1, flood queue length 0

Next 0×0(0)/0×0(0)

Last flood scan length is 0, maximum is 0

Last flood scan time is 0 msec, maximum is 0 msec

Neighbor Count is 0, Adjacent neighbor count is 0

Suppress hello for 0 neighbor(s)

R1#

5. From analysis, we know that: the reason that OSPF cannot form its own neighbor relations is OSPF think NBMA broadcast doesn’t support broadcast and multi-cast, thus it will not actively send out HELLO data packet of OSPF.

6. Configure manually OSPF neighbor relations of R1:

R1(config)#router ospf 1

R1(config-router)#neighbor 192.168.1.2

R1(config-router)#neighbor 192.168.1.3

R2(config)#router ospf 1

R2(config-router)#neighbor 192.168.1.1

R3(config)#router ospf 1

R3(config-router)#neighbor 192.168.1.1

7. System IOS will prompt the following information after configuration:

*Jun 18 15:36:16.743: %OSPF-5-ADJCHG: Process 1, Nbr 172.16.4.1 on Serial1/2 from LOADING to FULL, Loading Done

*Jun 18 15:36:16.747: %OSPF-5-ADJCHG: Process 1, Nbr 172.16.3.1 on Serial1/2 from LOADING to FULL, Loading Don

8. Check R1 neighbor table:

R1#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.3.1 1 FULL/DROTHER 00:01:31 192.168.1.2 Serial1/2

172.16.4.1 1 FULL/DR 00:01:57 192.168.1.3 Serial1/2

R1#

9. Apart from manual configuration, we may also change OSPF interface types, in this way router may automatically create OSPF neighbor relations. The configuration is very simple and error will not easily occur.

R1(config)#interface serial 1/2

R1(config-if)#ip ospf network broadcast

R1(config-if)#exit

10. Check interface information.

R1#show ip ospf interface serial 1/2

Serial1/2 is up, line protocol is up

Internet Address 192.168.1.1/24, Area 0

Process ID 1, Router ID 172.16.1.1, Network Type BROADCAST, Cost: 64

Transmit Delay is 1 sec, State DR, Priority 1

…………

R1#

11. Check OSPF neighbor table of R1, R2 and R2.

R1#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.3.1 1 FULL/DROTHER 00:00:32 192.168.1.2 Serial1/2

172.16.4.1 1 FULL/DR 00:00:33 192.168.1.3 Serial1/2

R1#

R2#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.1.1 1 FULL/BDR 00:00:30 192.168.1.1 Serial1/2

R2#

R3#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.1.1 1 FULL/BDR 00:00:39 192.168.1.1 Serial1/2

R3#

12. Observe OSPF neighbor table carefully, and you will find the following problems:

OSPF neighbor table of R1, indicate 172.16.4.1 is DR172.16.3.1 being DROTHER, and itself being BDR.

OSPF neighbor table of R2, indicate 172.16.1.1 is BDR, and itself being DR.

OSPF neighbor table of R3, indicate 172.16.1.1 is BDR and itself being DR.

With the following graphic, we get a better idea of DR and BDR.

6-2

The reason that this problem occur is the network topology of Frame-Relay is not full meshed. When R3 is establishing neighbors with R1, R3 know not the existence of R2. And when R2 is establishing neighbor with R1, R2 know not R3. At this time, the network is running two different OSPF auto systems.

13. There are also other problems: when errors occur on subnet of R3 172.16.4.0/24, R3 will broadcast LSA to R1, and R1 will not transfer this LSA to R3, because R1 thinks that R3 will be broadcasted by DR. Moreover, if errors occur on 172.16.1.0/24 of R1, R1 will broadcast to DR by default, i.e. broadcast to R3, but not to R2. Because as BDR, R1 will only broadcast LSA to DR, and other DROTHER broadcast will be done by DR, but as a DR, R3 will not broadcast to R2 after receiving LSA from R1, because R3 do not know that R2 is in the network.

14. To solve this problem, we should manually specify DR of network, because OSPF priority will affect DR selection, OSPF with priority 0 will never become DR, and OSPF with higher priority will become DR easily. By default, OSPF priority is 1, thus configure R2 and R3 priority as 0:

R2(config)#interface serial 1/2

R2(config-if)#ip ospf priority 0

R2(config-if)#exit

R2(config)#

R3(config)#interface serial 1/2

R3(config-if)#ip ospf priority 0

R3(config-if)#exit

15. Check neighbor table of all routers; from neighbor table you may see every OSPF router has their own roles:

R1#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.3.1 0 FULL/DROTHER 00:00:38 192.168.1.2 Serial1/2

172.16.4.1 0 FULL/DROTHER 00:00:39 192.168.1.3 Serial1/2

R1#

R2#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.1.1 1 FULL/DR 00:00:31 192.168.1.1 Serial1/2

R2#

R3#show ip ospf neighbor

Neighbor ID Pri State Dead Time Address Interface

172.16.1.1 1 FULL/DR 00:00:38 192.168.1.1 Serial1/2

R3#

16. We may also change OSPF interface types to avoid DR and BDR selection, and thus reduce errors occurrence in DR selection. For example, change the R1 interface network to P2MP (point-to-multipoint), and change R2 and R3 interface network types to P2P (point-to-point), because in the various network types of OSPF, both P2MP and P2P need not to select DR and BDR.

17. Besides, when configuring interface network types, we also have to pay attention to HELLO death interval time of interfaces, because different types of network have different interval time. Different types of HELLO time interval will result in the failure of OSPF neighbor relations establishing.

18. The following is network type and DR selection of an OSPF, and HELLO time interval table for reference.

6-3

19. Lab finished.

Hope to helpful for you!





[Report Dead Link] Please leave a comment or send email to report dead links, so that we will update new links within 24 hours.

Leave a Reply

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