Table of Contents
OSPF Hello packet
There are five types of packets in OSPF: Hello packets are the first packets sent and received for OSPF processing; OSPF Hello packets are used to discover and maintain neighbors.
OSPF Hello packet format
OSPF packets are encapsulated in IP; the protocol number in the IP header is 89. The destination IP address of a Hello packet is usually 22.214.171.124, which is a multicast address representing all OSPF routers. When running OSPF over NBMA, such as Frame Relay, the IP address specified in the neighbor command becomes the destination IP address.
OSPF packets have a 24-byte OSPF header to identify the type of OSPF packet; Hello packets are type 1.
See the following article on OSPF header format.
The Network Mask (32 bits) is the subnet mask of the interface to which the Hello packet is sent. In order to be a neighbor, the Network Mask must match; for an interface whose IP address is set to ip unnumbered, the Network Mask is 0.0.0.0.
The Hello Interval (16 bits) is the interval for sending Hello packets, and the default Hello Interval is 10 seconds in the current environment.
Options (8 bits), indicating the various OSPF router capability, such as whether stub areas are supported in the Options field.
Router Priority (8 bits) is used to select DR/BDR in a multi-access network such as Ethernet. The router with the higher Router Priority is selected as DR/BDR. If the Router Priority is set to 0, the router does not participate in the DR/BDR selection.
Router Dead Interval
If no Hello packets are received for a period of Router Dead Interval (32 bits), the neighbor is considered down. The Router Dead Interval must also match in order to establish a neighbor.
The Designated Router (32-bit) contains the IP address of the DR, which is “0.0.0.0” when the DR is being selected or when the network type is point-to-point without DR/BDR selection.
Backup Designated Router
The Backup Designated Router (32-bit) contains the IP address of the BDR, which is “0.0.0.0” when the BDR is being selected or when the network type is point-to-point without DR/BDR selection.
Neighbor (32 bits) stores the router ID that is recognized as the neighbor. The initial value is “0.0.0.0”. If there are multiple neighbors, Neighbor will have multiple lines.
Conditions for becoming a neighbor
Establish a neighbor with an OSPF Hello packet. In order to do so, the following information contained in the Hello packet must match.
- Area ID(OSPF header)
- AuType/Authentication(OSPF header)
- Network Mask
- Hello Interval
- Dead Interval
- Options(E/N bit)
In OSPF, the first step is to establish a neighbor. If you cannot successfully establish a neighbor, check the above information in the Hello packet.
Default value for Hello Interval/Dead Interval
The default value of Hello Interval/Dead Interval is determined by the network type of the OSPF enabled interface, as follows
|Network Type||Hello Interval||Dead Interval|
The network type of NON_BROADCAST would be Frame Relay or ATM interface. It is safe to assume that the default Hello/Dead Interval is 10/40 seconds, since Frame Relay/ATM is rarely used.
Change and verify Hello/Dead Interval.
The default Hello/Dead Interval is 10/40 seconds. This means that it will take about 40 seconds to recognize that a neighbor is down. To change the Hello/Dead Interval, use the following command in the interface configuration of an OSPF-enabled interface.
(config-if)#ip ospf hello-interval <hello>
(config-if)#ip ospf dead-interval <dead>
<interface-name> : Interface name
<hello> : Hello Interval value
<dead> : Dead Interval value
The recommended value for Dead Interval is 4 times the value of Hello Interval; when the value of Hello Interval is changed, Dead Interval will automatically be set to 4 times the value of Hello Interval. However, changing the Dead Interval setting will not automatically change the Hello Interval value.
Dead Interval can also be set to 1 second to allow for faster detection of neighbor down. configure the following in OSPF-enabled interface configuration mode.
(config-if)#ip ospf dead-interval minimal hello-multiplier <number>
<interface-name> : interface name
<number> : 3-20.
The value of Hello/Dead Interval is a condition for establishing a neighbor. When changing the settings, be careful to match the routers that should be neighbors.
To verify the value of Hello/Dead Interval, use the show ip ospf interface command. a sample of the show ip ospf interface command is shown below.
R1#show ip ospf interface FastEthernet0/0 is up, line protocol is up Internet Address 192.168.12.1/24, Area 0 Process ID 1, Router ID 126.96.36.199, Network Type BROADCAST, Cost: 1 Transmit Delay is 1 sec, State BDR, Priority 1 Designated Router (ID) 188.8.131.52, Interface address 192.168.12.2 Backup Designated router (ID) 184.108.40.206, Interface address 192.168.12.1 Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 oob-resync timeout 40 Hello due in 00:00:09 Supports Link-local Signaling (LLS) 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 220.127.116.11 (Designated Router) Suppress hello for 0 neighbor(s)
- OSPF Overview
- OSPF process flow
- OSPF Router ID : Identify OSPF routers
- What if the router ID of the OSPF router is duplicated?
- OSPF Neighbor and Adjacency
- OSPF DR/BDR
- How show ip ospf neighbor looks on Ethernet
- OSPF Network Type : Classification of OSPF-enabled interfaces
- Synchronization process of OSPF LSDB
- Problems with large-scale OSPF network
- OSPF Area – Inside the area, in detail; outside the area, just a summary
- OSPF Router Type
- OSPF LSA Type
- OSPF Area Type
- OSPF Basic Configuration and Verification Commands
- Details of enabling OSPF on the interface
- OSPF Advertising Loopback Interface
- Configuring and Verifying OSPF Hello/Dead interval
- OSPF Cost Configuration and Verification
- Configuring and Verifying OSPF Router Priority
- Configuring OSPF Neighbor Authentication
- Neighbor Authentication over Virtual-link
- OSPF Configuring and Verifying Stub area [Cisco]
- OSPF Stub Area Configuration Example [Cisco]
- OSPF default route generation : default-information originate command
- Configuration Example of OSPF default route generation : stub area
- OSPF Virtual-Link : Virtual area 0 point-to-point link
- Configuring and Verifying OSPF Virtual-link [Cisco]
- OSPF Virtual-link Configuration Example [Cisco]
- OSPF Virtual-link for discontinuous backbone configuration example
- OSPF Route Summary and Configuration
- Cisco OSPF Route Summary Configuration Example
- OSPF Route Type Preference
- Why the OSPF neighbor state gets stuck in Exstart?
- OSPF packet type and header format
- OSPF Hello Packet
- OSPF DD(Database Description) Packet
- OSPF LSR(Link State Request) Packet
- OSPF LSU(Link State Update) Packet
- OSPF LSAck(Link State Acknowledgement) Packet
- Limitation of OSPF redistribution routes – redistribute maximum-prefix command
- Overview of LSA Filters for OSPF – Filter LSA Type 3/Type 5
- Configuration example of LSA type 3 filter
- Configuration example of LSA type 5 filter
- OSPFv3 Configuration Example [Cisco]
- Configuration Example of OSPFv3 Route Summary [Cisco]