Dijkstra's Algorithm: Shortest Path - Easy To Understand OSPF Packet Details
OSPF has five types of packets used for various reasons. Table 8-1 documents the different OSPF packet types and describes their functionality.
All the OSPF packet types share a common 20-byte OSPF protocol header. Figure 8-1 shows the common OSPF protocol header format.
Figure 8-1. Common OSPF Protocol Header Format
Hello Packets
Hello packets are the first type of packets in OSPF. Figure 8-2
illustrates the Hello packet format. Hello packets are used to form a
neighbor relationship between two routers. In environments that include
broadcast/nonbroadcast media, Hello packets are used to elect the
designated (DR) and backup designated (BDR) routers. On broadcast media,
the destination address of the Hello packets is 224.0.0.5. On
nonbroadcast media, the destination address is unicast.
Figure 8-2. Hello Packet Format
The list that follows describes the fields in the Hello packet:
Database Description Packets
The second type of OSPF
packet, the database description (DBD) packet, is used mostly during the
database exchange. The first DBD packet is used to elect the master and
slave relationship and to set the initial sequence number elected by
the master. The router with the highest router ID becomes the master and
initiates the database synchronization. The master sends the sequence
number, and the slave acknowledges it. After the master and the slave
are elected, the database synchronization starts; in this process, the
headers of all the LSAs are exchanged with neighbors. Figure 8-3 illustrates the DBD packet format.
Figure 8-3. Database Description Packet FormatLink-State Request Packets
The Type 3 OSPF packet, a
link-state request packet, is sent if part of the database is missing or
out-of-date. The link-state request packet is used to retrieve that
precise piece of database information that is missing. Link-state
packets are also used after the DBD exchange is finished to request the
LSAs that have been seen during the DBD exchange. Figure 8-4 illustrates the link-state request packet format.
Figure 8-4. Link-State Request Packet Format
The list that follows describes the fields in the link-state request packet:
Link-State Update Packets
OSPF packet Type 4, the link-state update packet,
implements flooding. Several LSAs are included in a single packet.
Link-state update packets are also sent in response to link-state request
packets. Flooded LSAs are acknowledged in the LSA acknowledgment
packet. If an LSA is not acknowledged, it is retransmitted every
retransmit interval (5 seconds, by default). Figure 8-5 illustrates the link-state update packet format.
Figure 8-5. Link-State Update Packet Format
As Figure 8-5 shows, this packet contains the number of LSAs (for example, 10 or 20 LSAs), followed by the LSA itself.
Link-State Acknowledgment Packet
The last type of OSPF packet, the link-state acknowledgment packet, is used to acknow-ledge
each LSA. This packet is sent in response to link-state update packets.
Multiple LSAs can be acknowledged in a single link-state acknowledgment
packet. This packet is respon-sible for the reliable delivery of
link-state update packets. Figure 8-6 illustrates the link-state acknowledgment packet format.
Figure 8-6. Link-State Acknowledgment Packet Format
Link-state acknowledgment packets are sent as
multicasts. If the state of the router is DR or BDR, the acknowledgment
is sent to the OSPF router multicast address of 224.0.0.5. If the state
of the router is not DR or BDR, the acknowledgment is sent to the all DR
router multicast address of 224.0.0.6.
|
Monday, August 13, 2012
OSPF Packet Details & Dijkstra's Algorithm: Shortest Path Video
Taken from http://cisco.iphelp.ru/faq/5/ch08lev1sec1.html#ch08fig01
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment