ospf infinite skills

39
Page | 1

Upload: ssarachman1

Post on 19-Jun-2015

141 views

Category:

Technology


1 download

DESCRIPTION

OSPF Tutorial

TRANSCRIPT

Page 1: Ospf infinite skills

P a g e | 1

Page 2: Ospf infinite skills

P a g e | 2

Page 3: Ospf infinite skills

P a g e | 3

Page 4: Ospf infinite skills

P a g e | 4

Page 5: Ospf infinite skills

P a g e | 5

Page 6: Ospf infinite skills

P a g e | 6

Page 7: Ospf infinite skills

P a g e | 7

Down

This is the first OSPF neighbor state. It means that no information (hellos) has been received from this neighbor, but hello packets can still be sent to the neighbor in this state.

During the fully adjacent neighbor state, if a router doesn't receive hello packet from a neighbor within the RouterDeadInterval time (RouterDeadInterval = 4*HelloInterval by default) or if the manually configured neighbor is being removed from the configuration, then the neighbor state changes from Full to Down.

Attempt

This state is only valid for manually configured neighbors in an NBMA (NON-BROADCAST MULTI-ACCESS) environment. In Attempt state, the router sends unicast hello packets every poll interval to the neighbor, from which hellos have not been received within the dead interval.

Init

This state specifies that the router has received a hello packet from its neighbor, but the receiving router's ID was not included in the hello packet. When a router receives a hello packet from a neighbor, it should list the sender's router ID in its hello packet as an acknowledgment that it received a valid hello packet.

2-Way

This state designates that bi-directional communication has been established between two routers. Bi-directional means that each router has seen the other's hello packet. This state is attained when the router receiving the hello packet sees its own Router ID within the received hello packet's neighbor field. At this state, a router decides whether to become adjacent with this neighbor. On broadcast media and non-broadcast multiaccess networks, a router becomes full only with the designated router (DR) and the backup designated router (BDR); it stays in the 2-way state with all other neighbors. On Point-to-point and Point-to-multipoint networks, a router becomes full with all connected routers.

At the end of this stage, the DR and BDR for broadcast and non-broadcast multiacess networks are elected. For more information on the DR election process, refer to DR Election.

Note: Receiving a Database Descriptor (DBD) packet from a neighbor in the init state will also a cause a transition to 2-way state.

Exstart

Page 8: Ospf infinite skills

P a g e | 8

Once the DR and BDR are elected, the actual process of exchanging link state information can start between the routers and their DR and BDR.

In this state, the routers and their DR and BDR establish a master-slave relationship and choose the initial sequence number for adjacency formation. The router with the higher router ID becomes the master and starts the exchange, and as such, is the only router that can increment the sequence number. Note that one would logically conclude that the DR/BDR with the highest router ID will become the master during this process of master-slave relation. Remember that the DR/BDR election might be purely by virtue of a higher priority configured on the router instead of highest router ID. Thus, it is possible that a DR plays the role of slave. And also note that master/slave election is on a per-neighbor basis.

Exchange

In the exchange state, OSPF routers exchange database descriptor (DBD) packets. Database descriptors contain link-state advertisement (LSA) headers only and describe the contents of the entire link-state database. Each DBD packet has a sequence number which can be incremented only by master which is explicitly acknowledged by slave. Routers also send link-state request packets and link-state update packets (which contain the entire LSA) in this state. The contents of the DBD received are compared to the information contained in the routers link-state database to check if new or more current link-state information is available with the neighbor.

Loading

In this state, the actual exchange of link state information occurs. Based on the information provided by the DBDs, routers send link-state request packets. The neighbor then provides the requested link-state information in link-state update packets. During the adjacency, if a router receives an outdated or missing LSA, it requests that LSA by sending a link-state request packet. All link-state update packets are acknowledged.

Full

In this state, routers are fully adjacent with each other. All the router and network LSAs are exchanged and the routers' databases are fully synchronized.

Full is the normal state for an OSPF router. If a router is stuck in another state, it's an indication that there are problems in forming adjacencies. The only exception to this is the 2-way state, which is normal in a broadcast network. Routers achieve the full state with their DR and BDR only. Neighbors always see each other as 2-way.

Neighbors Stuck in Exstart/Exchange State

The problem occurs most frequently when attempting to run OSPF between a Cisco router and another vendor's router. The problem occurs when the maximum transmission unit (MTU) settings for neighboring router interfaces don't match. If the router with the higher MTU sends a packet

Page 9: Ospf infinite skills

P a g e | 9

larger that the MTU set on the neighboring router, the neighboring router ignores the packet.0 When this problem occurs, the output of the show ip ospf neighbor command displays this

Introduction

This document provides sample configurations for Open Shortest Path First (OSPF) over Frame Relay subinterfaces.

Prerequisites

Requirements

Before you attempt this configuration, make sure that you meet these requirements:

A basic understanding of Frame Relay and OSPF configuration

Refer to Configuring OSPF and Configuring and Troubleshooting Frame Relay for more information.

Components Used

The information in this document is based on these software and hardware versions:

Cisco 2503 routers Cisco IOS® software version 12.3(3) on both routers

The information in this document was created from the devices in a specific lab environment. All of the devices used in this document started with a cleared (default) configuration. If your network is live, make sure that you understand the potential impact of any command.

Conventions

For more information on document conventions, refer to Cisco Technical Tips Conventions.

Page 10: Ospf infinite skills

P a g e | 10

Background Information

In order to configure and troubleshoot OSPF over a network, you must have a good understanding of the underlying network topology. The neighbor discovery mechanism, election of Designated Router (DR) and Backup Designated Router (BDR), and update flooding depend on it. The underlying Layer 2 topology can be one of these:

Broadcast multi-access (for example, Ethernet)—A Broadcast network is one which allows broadcast or multicast packets to be sent over the network and hence every device able to communicate directly with every other device in the segment. A multi-access network is a network that connects more than two devices. Refer to Initial Configurations for OSPF Over Broadcast Media for more information.

Point-to-Point (such as serial links with Point-to-Point and High-Level Data Link Control (PPP/HDLC))—point-to-point networks also allow broadcast or multicast packets to be sent over the network, and these networks connect only two devices on the segment. Refer to Initial Configurations for OSPF over a Point-to-Point Link for more information.

Non-Broadcast multi-access (NBMA), such as Frame Relay—These networks do not support broadcasts or multicasts, but can connect more than devices and are multi-access in nature. Refer to Initial Configurations for OSPF over Non-Broadcast Links for more information.

Point-to-Multipoint—This is a collection of point-to-point links between various devices on a segment. These networks also allow broadcast or multicast packets to be sent over the network. These networks can represent the multi-access segment as multiple point-to-point links that connect all the devices on the segment.

When OSPF is run on a network, two important events happen before routing information is exchanged:

Neighbors are discovered using multicast hello packets. DR and BDR are elected for every multi-access network to optimize the adjacency building process. All the routers in that segment should

be able to communicate directly with the DR and BDR for proper adjacency (in the case of a point-to-point network, DR and BDR are not necessary since there are only two routers in the segment, and hence the election does not take place).

For a successful neighbor discovery on a segment, the network must allow broadcasts or multicast packets to be sent.

In the broadcast multi-access Layer 2 topology, broadcasts are supported; therefore, a router that runs OSPF can discover OSPF neighbors automatically and elect any router as DR and BDR since any device can talk to all other routers in that broadcast segment.

In a point-to-point topology, neighbors are discovered automatically since neighbors are directly connected to each other through a point-to-point link, and broadcast or multicast packets are forwarded over the network; however, the DR and BDR election does not take place as explained earlier.

Page 11: Ospf infinite skills

P a g e | 11

In an NBMA network topology, which is inherently nonbroadcast, neighbors are not discovered automatically. OSPF tries to elect a DR and a BDR due to the multi-access nature of the network, but the election fails since neighbors are not discovered. Neighbors must be configured manually to overcome these problems. Also, additional configuration is necessary in a hub and spoke topology to make sure that the hub routers, which have connectivity with every other spoke router, are elected as the DR and BDR. Alternatively, you can change the configuration on the NBMA interface to make OSPF believe that it is another network type that does not have these problems.

The correct configuration is necessary for the proper operation of OSPF.

Frame Relay subinterfaces can run in two modes:

Point-to-Point—When a Frame Relay point-to-point subinterface is configured, the subinterface emulates a point-to-point network and OSPF treats it as a point-to-point network type.

Multipoint—When a Frame Relay multipoint subinterface is configured, OSPF treats this subinterface as an NBMA network type.

Cisco IOS software uses the ip ospf network command to allow the flexibility run OSPF on an interface in different modes:

ip ospf network {broadcast | non-broadcast | {point-to-multipoint [non-broadcast] | point-to-point}}

The Configure section of this document contains sample configurations for OSPF over Frame Relay point-to-point subinterfaces, OSPF over Frame Relay multipoint subinterfaces with broadcast, non-broadcast, and point-to-multipoint networks.

Configure

In this section, you are presented with the information to configure the features described in this document.

Note: Use the Command Lookup Tool (registered customers only) to find more information on the commands used in this document.

Network Diagram

This document uses the network setup shown here:

Page 12: Ospf infinite skills

P a g e | 12

Configurations

This document uses the configurations shown in this section.

Point-to-Point Configuration

R4-2503

interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial0 no ip address encapsulation frame-relay !--- To enable Frame Relay encapsulation !--- on the interface. no keepalive ! interface Serial0.1 point-to-point!--- The subinterface is configured to!--- function as a point-to-point link!--- with this command. ip address 1.1.1.2 255.255.255.0 frame-relay interface-dlci 16!--- To assign a data-link connection identifier!--- (DLCI) to a specified Frame Relay subinterface.!--- Without this command, all the DLCIs are assigned

Page 13: Ospf infinite skills

P a g e | 13

!--- to the physical interface. ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

R1-2503

interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! interface Serial0 no ip address encapsulation frame-relay!--- To enable Frame Relay encapsulation on!--- the interface. no keepalive clockrate 2000000 ! interface Serial0.1 point-to-point!--- The subinterface is configured to function!--- as a point-to-point link with this command. ip address 1.1.1.1 255.255.255.0 frame-relay interface-dlci 16!--- To assign a data-link connection identifier!--- (DLCI) to a specified Frame Relay subinterface.!--- Without this command, all the DLCIs are!--- assigned to the physical interface. ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

Verification Tips for Point-to-Point Configuration

Page 14: Ospf infinite skills

P a g e | 14

The commands outlined here are useful for verification:

show ip ospf neighbor—This command is used to display OSPF-neighbor information. show ip ospf interface—This command is used to display OSPF-related interface information.

The outputs of these commands are shown here:

R4-2503# show ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 2.2.2.2 1 FULL/ - 00:00:33 1.1.1.1 Serial0.1

Note: In this output, the OSPF neighbor state is shown as "FULL / -", but the DR and BDR state is not indicated. This is because there is no DR and BDR election on a point-to-point link.

R4-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0

R4-2503# show ip ospf interface s0.1 Serial0.1 is up, line protocol is up Internet Address 1.1.1.2/24, Area 0 Process ID 1, Router ID 3.3.3.3, Network Type POINT_TO_POINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_POINT, Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:09

Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 2.2.2.2 Suppress hello for 0 neighbor(s)

R1-2503# show ip ospf neighbor

Page 15: Ospf infinite skills

P a g e | 15

Neighbor ID Pri State Dead Time Address Interface 3.3.3.3 1 FULL/ - 00:00:37 1.1.1.2 Serial0.1

R1-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0 R1-2503# show ip ospf interface s0.1 Serial0.1 is up, line protocol is up Internet Address 1.1.1.1/24, Area 0 Process ID 1, Router ID 2.2.2.2, Network Type POINT_TO_POINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_POINT, Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:03

Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 3.3.3.3 Suppress hello for 0 neighbor(s)

Multipoint Configuration with Broadcast Network

In this configuration, the network type is changed to broadcast with the ip ospf network broadcast command. Now, the NBMA network is viewed as a broadcast multi-access network where DR and BDR election takes place. The frame relay map commands are also set to forward broadcast addresses.

R4-2503

interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial0

Page 16: Ospf infinite skills

P a g e | 16

no ip address encapsulation frame-relay no keepalive ! interface Serial0.2 multipoint!--- The subinterface is treated as a multipoint link. ip address 1.1.1.2 255.255.255.0 ip ospf network broadcast!--- This command is used to define the network

!--- type as broadcast. The network type is defined!--- on non-broadcast networks so as to not configur!--- the neighbors explicitly. frame-relay map ip 1.1.1.1 16 broadcast!--- To define the mapping between a destination!--- protocol address and the data-link connection!--- identifier (DLCI) used to connect to the!--- destination address. The broadcast keyword!--- is used to forward broadcasts and multicasts!--- to this address. ! ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

R1-2503

interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! ! interface Serial0 no ip address encapsulation frame-relay

Page 17: Ospf infinite skills

P a g e | 17

no keepalive clockrate 2000000 ! interface Serial0.2 multipoint!--- The subinterface is treated as a multipoint link. ip address 1.1.1.1 255.255.255.0 ip ospf network broadcast!--- This command is used to define the network!--- type as broadcast. The network type is defined

!--- on non-broadcast networks so as not configure!--- the neighbors explicitly. frame-relay map ip 1.1.1.2 16 broadcast!--- To define the mapping between a!--- destination protocol address and the data-link!--- connection identifier (DLCI) used to connect!--- to the destination address. The broadcast!--- keyword is used to forward broadcasts and multicasts!--- to this address. ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

Note: If a subinterface is configured as point-to-point, the same subinterface cannot be reassigned as a multipoint subinterface unless the router is reloaded. In this case, a different subinterface is used for the multipoint configuration.

Verification Tips for Multipoint Configuration with Broadcast Network

R4-2503# show ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 2.2.2.2 1 FULL/BDR 00:00:32 1.1.1.1 Serial 0.2 R4-2503# show ip ospf interface s0

Page 18: Ospf infinite skills

P a g e | 18

%OSPF: OSPF not enabled on Serial0 R4-2503# show ip ospf interface s0.2 Serial0.2 is up, line protocol is up Internet Address 1.1.1.2/24, Area 0 Process ID 1, Router ID 3.3.3.3, Network Type BROADCAST, Cost: 64 Transmit Delay is 1 sec, State DR, Priority 1 Designated Router (ID) 3.3.3.3, Interface address 1.1.1.2 Backup Designated router (ID) 2.2.2.2, Interface address 1.1.1.1 Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:05 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 2.2.2.2 (Backup Designated Router) Suppress hello for 0 neighbor(s) R1-2503# show ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 3.3.3.3 1 FULL/DR 00:00:35 1.1.1.2 Serial0.2 R1-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0 R1-2503# show ip ospf interface s0.2 Serial0.2 is up, line protocol is up Internet Address 1.1.1.1/24, Area 0 Process ID 1, Router ID 2.2.2.2, Network Type BROADCAST, Cost: 64 Transmit Delay is 1 sec, State BDR, Priority 1 Designated Router (ID) 3.3.3.3, Interface address 1.1.1.2 Backup Designated router (ID) 2.2.2.2, Interface address 1.1.1.1 Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5

Page 19: Ospf infinite skills

P a g e | 19

oob-resync timeout 40 Hello due in 00:00:01 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 3.3.3.3 (Designated Router) Suppress hello for 0 neighbor(s)

Multipoint Configuration with Non-Broadcast Network

In this configuration, the network is non-broadcast, which does not allow neighbors to be discovered automatically. The neighbor command is used to manually configure OSPF neighbors. However, this command is necessary only with Cisco IOS software versions earlier than 10.0. As an alternate solution, issue the ip ospf network command to change the default network type (see the Multipoint Configuration with Broadcast Network configuration example). Refer to the "Avoiding DRs and neighbor Command on NBMA" section of OSPF Design Guide for more information. DR and BDR are elected due to the multi-access nature.

R4-2503

interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial0 no ip address encapsulation frame-relay no keepalive ! interface Serial0.2 multipoint ip address 1.1.1.2 255.255.255.0 frame-relay map ip 1.1.1.1 16 broadcast ip ospf priority 2 !--- This command assigns a higher priority for this router on this interface, !--- so that it gets elected as the DR. In case of a Hub and Spoke topology, !--- the hub should be elected as the DR as it has connectivity to all the spokes.

Page 20: Ospf infinite skills

P a g e | 20

! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

R1-2503

interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! interface Serial0 no ip address encapsulation frame-relay no keepalive clockrate 2000000 ! interface Serial0.2 multipoint ip address 1.1.1.1 255.255.255.0 frame-relay map ip 1.1.1.2 16 broadcast ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 neighbor 1.1.1.2!--- Used to manually configure neighbors.

Verification Tips for Multipoint Configuration with Non-Broadcast Network

R4-2503# show ip ospf neighbor

Page 21: Ospf infinite skills

P a g e | 21

Neighbor ID Pri State Dead Time Address Interface 2.2.2.2 1 FULL/BDR 00:01:56 1.1.1.1 Serial0.2 R4-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0 R4-2503# show ip ospf interface s0.2 Serial0.2 is up, line protocol is up Internet Address 1.1.1.2/24, Area 0 Process ID 1, Router ID 3.3.3.3, Network Type NON_BROADCAST, Cost: 64 Transmit Delay is 1 sec, State DR,Priority 2 Designated Router (ID) 3.3.3.3, Interface address 1.1.1.2 Backup Designated router (ID) 2.2.2.2, Interface address 1.1.1.1 Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:25 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 2.2.2.2 (Backup Designated Router) Suppress hello for 0 neighbor(s) R1-2503# show ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 3.3.3.3 2 FULL/DR 00:01:52 1.1.1.2 Serial0.2 R1-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0 R1-2503# show ip ospf interface s0.2 Serial0.2 is up, line protocol is up Internet Address 1.1.1.1/24, Area 0 Process ID 1, Router ID 2.2.2.2, Network Type NON_BROADCAST, Cost: 64

Page 22: Ospf infinite skills

P a g e | 22

Transmit Delay is 1 sec, State BDR, Priority 1 Designated Router (ID) 3.3.3.3, Interface address 1.1.1.2 Backup Designated router (ID) 2.2.2.2, Interface address 1.1.1.1 Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:01 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 3.3.3.3 (Designated Router) Suppress hello for 0 neighbor(s)

Multipoint Configuration with Point-to-Multipoint Network

In this configuration, the network type is changed with the ip ospf network point-to-multipoint command to function as a collection of point-to-point links. Neighbors are discovered automatically and DR and BDR election does not take place.

R4-2503

interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial0 no ip address encapsulation frame-relay no keepalive ! interface Serial0.2 multipoint ip address 1.1.1.2 255.255.255.0 ip ospf network point-to-multipoint!--- To configure an interface as!--- point-to-multipoint for non-broadcast media. frame-relay map ip 1.1.1.1 16 broadcast !

Page 23: Ospf infinite skills

P a g e | 23

! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

R1-2503

interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! interface Serial0 no ip address encapsulation frame-relay no keepalive clockrate 2000000 ! interface Serial0.2 multipoint ip address 1.1.1.1 255.255.255.0 ip ospf network point-to-multipoint!--- To configure an interface as!--- point-to-multipoint for non-broadcast media. frame-relay map ip 1.1.1.2 16 broadcast ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 !

Verification Tips for Multipoint Configuration with Point-to-Multipoint Network

R4-2503# show ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface

Page 24: Ospf infinite skills

P a g e | 24

2.2.2.2 1 FULL/ - 00:01:58 1.1.1.1 Serial0.2 R4-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0 R4-2503# show ip ospf interface s0.2 Serial2.1 is up, line protocol is up Internet Address 1.1.1.2/24, Area 0 Process ID 1, Router ID 3.3.3.3, Network Type POINT_TO_MULTIPOINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_MULTIPOINT, Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:07 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 2 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 2.2.2.2 Suppress hello for 0 neighbor(s)

R1-2503# show ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 3.3.3.3 1 FULL/ - 00:01:49 1.1.1.2 Serial0.2 R1-2503# show ip ospf interface s0 %OSPF: OSPF not enabled on Serial0 R1-2503# show ip ospf interface s0.2 Serial0.2 is up, line protocol is up Internet Address 1.1.1.1/24, Area 0 Process ID 1, Router ID 2.2.2.2, Network Type POINT_TO_MULTIPOINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_MULTIPOINT, Timer intervals configured, Hello 30, Dead 120, Wait 120, Retransmit 5

Page 25: Ospf infinite skills

P a g e | 25

oob-resync timeout 40 Hello due in 00:00:00 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 2 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 3.3.3.3 Suppress hello for 0 neighbor(s)

Verify

In order to verify your configurations, use the subsections provided in the Configure section of this document.

Troubleshoot

This section provides information you can use to troubleshoot your configuration.

Before you troubleshoot any OSPF neighbor-related issues on an NBMA network, it is important to remember that an NBMA network can be configured in these modes of operation with the ip ospf network command:

Point-to-Point Point-to-Multipoint Broadcast NBMA

The Hello and Dead Intervals of each mode are described in this table:

Network Type Hello Interval (secs) Dead Interval (secs)

Point-to-Point 10 40

Point-to-Multipoint 30 120

Broadcast 10 40

Non-Broadcast 30 120

Page 26: Ospf infinite skills

P a g e | 26

When OSPF is configured on a physical interface (for example, interface S0) of a non broadcast multi-access technology such as Frame Relay, the default network type of NON_BROADCAST is assigned. When OSPF is configured on point-to-point subinterfaces, the default interface type of POINT_TO_POINT is assigned. When OSPF is configured on multipoint subinterfaces, the default interface type of NON_BROADCAST is assigned.

When the NBMA network is made up of a combination of physical and logical interfaces (subinterfaces) on different routers, different OSPF network types come into play. Hello mismatches are likely to occur in such cases; as a result, OSPF adjacencies are not formed.

Refer to Problems with Running OSPF in NBMA Mode over Frame Relay and Troubleshooting OSPF for more information on how to troubleshoot OSPF.

Page 27: Ospf infinite skills

P a g e | 27

Page 28: Ospf infinite skills

P a g e | 28

Page 29: Ospf infinite skills

P a g e | 29

http://www.itcertnotes.com/2011/12/ospf-configuration-over-nbma.html

Page 30: Ospf infinite skills

P a g e | 30

Understanding OSPF Neighbor Relationship

An OSPF router goes through several states before the neighbor is considered fully adjacent.

But, before going to the adjacent process, let’s understand some important terms in OSPF:

Router-ID:

Router-ID simply means the name of this router in the OSPF domain. Before an OSPF router can send any OSPF messages, it must choose a unique 32-bit identifier called the router identifier. Cisco routers choose the following sequence to choose their Router-ID.

1. If you configure Router-ID manually, it will be the Router-ID2. If the router-ID is not configured manually and the loopback interface exists, highest active Loopback address will be the Router-ID3. If Loopback interface doesn’t exists, then the highest active physical interface address.

Some important points to be noted about Router ID: The Cisco OSPF will continue to use a RID learned from a physical interface even if the interface subsequently fails or deleted. The RID does not have to reachable The interface from which the RID is taken does not have to be matched by an OSPF network command Routers consider changing the OSPF RID when the OSPF process is restarted or when the RID changed via the configuration. If a RID changes, the rest of the routers in the same area need to perform a new SPF calculation. If the RID is configured via Router-id command and the command remains unchanged, RID will never change for that router.

Hello Protocol:

The Hello protocol performs many functions: Discover OSPF speaking neighbors It advertises several parameters on which two routers must agree before they can become neighbors Hello packets act as keepalives between the neighbors OSPF speaking routers periodically send a Hello packet out each OSPF enabled interface. This period is called HelloInterval. In Cisco networks,

o Hello messages sent once every 10Sec on Broadcast / P2P networkso Hello messages sent once every 30Sec on NBMA networks

Contents of Hello Packet:

Router-ID Area ID * Subnet Mask * Hello Timer * Dead Timer * DR/BDR Neighbors List Priority

Page 31: Ospf infinite skills

P a g e | 31

Authentication if any * Stub flag

* Mandatory fields to be matched. If any of these parameters don’t match, the two routers don’t form a neighbor relationship.

DR / BDR:

In OSPF, each shared segment will have a DR and BDR, mainly to prevent the unnecessary flooding of the LSAs. Without, DR/BDR, in any shared network, we should have n(n-1)/2 adjacencies. Each router in a shared segment forms full adjacency with only DR and BDR. There is no preemption in the DR/BDR elections. DR/BDR elections are influenced by Priority and Router-ID.

o Each OSPF interface has a priority value of 0-255.o In Cisco networks, default priority value is 1.o Routers with a priority of 0 are ineligible to become DR/BDR.

Election process for DR/BDR: (from Jeff Doyle TCP/IP Volume I) After 2-way communication has been established with one or more neighbors, examine the priority, DR/BDR fields in a neighbor’s Hello

packet. List all the routers which are eligible for election, all routers declaring themselves to be the DR and all routers declaring themselves to

be the BDR. From this list of eligible routers make a subset of the routers, not claiming to be the DR (routers declaring themselves to be the DR

cannot be elected BDR) If one more neighbors in this subset include its own interface address in the BDR field, the neighbor with the highest priority becomes

the BDR, in case of tie, highest Router ID will be chosen. If no router in the subset claims to be the BDR, the neighbor with the highest priority becomes the BDR, in case of tie, highest Router ID

will be chosen. If one more of the eligible routers include their own address in the DR field, the neighbor with the highest priority becomes the DR, in

case of tie, highest Router ID will be chosen. If no router is claiming to be a DR, the newly elected BDR gets promoted to the DR. When OSPF is discovering the neighbors, if a DR and BDR exist, the router accepts them. If there is no DR and BDR,

then only elections will happen.Different states in OSPF neighbor adjacency process:

Down State Attempt Init 2-way Exstart Exchange Loading Full

Down:

This is the first OSPF neighbor state. It means that no Hello has been received from the neighbor.

Page 32: Ospf infinite skills

P a g e | 32

Attempt:This state is only valid for manually configured neighbors in an NBMA environment.

Init:This state indicates that the router has received a hello packet from its neighbor, but the receiving router’s ID was not found in the Hello

packet

2-Way:This state indicates that the bi-directional communication has been established between the 2 neighbors.

Am I listed as your neighbor in your Hello packet?Yes: reset the dead timer, and the Hello processing ends at this step.No: Add as new neighborDR/BDR election occurs at the end of this stage.

In broadcast networks, DROTHERS will be always at 2-way state.R1(config-router)#do show ip ospf neiNeighbor ID Pri State Dead Time Address Interface2.2.2.2 1 2WAY/DROTHER 00:00:38 10.1.1.2 FastEthernet0/03.3.3.3 1 FULL/DR 00:00:39 10.1.1.3 FastEthernet0/04.4.4.4 1 FULL/BDR 00:00:32 10.1.1.4 FastEthernet0/0R1(config-router)#

R2(config-router)#do show ip ospf neiNeighbor ID Pri State Dead Time Address Interface1.1.1.1 1 2WAY/DROTHER 00:00:30 10.1.1.1 FastEthernet0/03.3.3.3 1 FULL/DR 00:00:37 10.1.1.3 FastEthernet0/04.4.4.4 1 FULL/BDR 00:00:31 10.1.1.4 FastEthernet0/0R2(config-router)#

R3(config-router)#do show ip ospf neiNeighbor ID Pri State Dead Time Address Interface1.1.1.1 1 FULL/DROTHER 00:00:38 10.1.1.1 FastEthernet0/02.2.2.2 1 FULL/DROTHER 00:00:35 10.1.1.2 FastEthernet0/04.4.4.4 1 FULL/BDR 00:00:39 10.1.1.4 FastEthernet0/0R3(config-router)#

Exstart:In this state, the router and its neighbor establish a master/slave relationship and determine the initial DD sequence number in preparation for

the exchange of Database Description (DBD) Packets.The neighbor with the highest Router ID becomes the master.

Exchange:In this state, OSPF router exchange DBD packets.DBD packet contains the summary of the LSA headers.DBDs are acknowledged and reviewed in this state.

Page 33: Ospf infinite skills

P a g e | 33

Loading:Slave requests the details (LSR)Master sends updates (LSU)Master requests the details (LSR)Slave sends updates (LSU)

Full:In this state, routers are fully adjacent with each other and their database is synchronized.

It’s time to run the Dijkstra’s SPF algorithm!

http://www.slideshare.net/professordkinney/lesson-3-slideshow

http://professordkinney.com/