cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2095
Views
10
Helpful
4
Replies

OSPF packet

Arjun Dabol
Level 1
Level 1

Hi


Can someone explain me in simple networking terms ...where does OSPF packet fits in a typical IP packet ?

and since 'OSPF LSA' carries prefix and other info..where does that fit in over all IP Packet concept ?

Is there any encapsulation happening here?

Thanks

2 Accepted Solutions

Accepted Solutions

Joseph W. Doherty
Hall of Fame
Hall of Fame

 ...where does OSPF packet fits in a typical IP packet ?

As also noted by Jon, it's the payload of an IP packet, specifically of a OSPF protocol IP packet.

and since 'OSPF LSA' carries prefix and other info..where does that fit in over all IP Packet concept ?

It doesn't, beyond being one of the defined IP packet protocol types.

I.e. IP, itself, just tells us such a packet is one used by OSPF, it's then up to OSPF to make meaning of the IP packet's payload.

View solution in original post

Rolf Fischer
Level 9
Level 9

Hi,

and since 'OSPF LSA' carries prefix and other info..where does that fit in over all IP Packet concept ?

Is there any encapsulation happening here?

This is a very good question!

When designing a large OSPF network, it can be challenging to decide how many routers you want to put in a single OSPF area.

I heard a very interesting advice in a CiscoLive session: 

BRKRST-2337 - OSPF Deployment in Modern Networks (at ~17:30 minutes)

"Keep router LSAs under MTU size - avoid IP fragmentation."

Although IP fragmentation would (of course) work with very large OSPF Router-LSAs, you should avoid it. In simple terms, Router-LSAs carry the link-information of all the router-interfaces in an area (the details are quite complicated). A typical IP-packet sent over Ethernet with 1500 byte MTU would be able to encapsulate a OSPF Router-LSA that describes 119 links without the need for fragmentation. Depending on the type of connections this would typically correspond to ~50 routers.

HTH
Rolf

[EDIT]:

In order to produce a wireshark capture of fragmented OSPF packets I set up a quick lab with a large number of OSPF-enabled loopback interfaces (see attached file).

R1#show ip ospf database

                Router Link States (Area 0)
Link ID         ADV Router      Age         Seq#       Checksum Link count
1.1.1.1         1.1.1.1         347         0x80000010 0x0025B4 120
2.2.2.2         2.2.2.2         515         0x80000002 0x003BF8 1

                Net Link States (Area 0)
Link ID         ADV Router      Age         Seq#       Checksum
192.168.12.1    1.1.1.1         514         0x80000001 0x00C7EB

Depending on the type of connections this would typically correspond to ~50 routers.

For the sake of completeness I want to point out that we're talking about ~50 (up to 118) neighbor-routers, since every router generates a Router-LSA only for its own interfaces in that area. So this is not really the maximum number of routers in an area - its rather the maximum number of neighbors in the same area...

View solution in original post

4 Replies 4

Jon Marshall
Hall of Fame
Hall of Fame

There are different types of OSPF packet but put simply they are just like any other IP packet in the sense there is a L2 header, then a L3 IP header, then a payload and then a trailer.

The protocol field in the IP header is 89 which is for OSPF and then the payload is the OSPF packet.

Jon

vlopesba
Level 1
Level 1

What Jon told is pretty much truth

Just completing: although generally reffer TCP/IP refering to networks this is not really accurate. In OSPF case for example, it is not TCP/IP packet because OSPF doesn't rely on TCP for its connections: OSPF takes care of transport itself (and thus the IP protocol number).

If you compare a OSPF packet to Telnet, TFTP, HTTP or even BGP this diference is more clear: while OSPF header is seen right after Network Header, Telnet/TFTP/BGP/HTTP will have a TCP or UDP header (transport) prior to the protocol payload itself

OSPF and EIGRP are considered to be Network Layer protocol although there are some arguments that they have L7 functionalities. BGP and RIP for example do basically the same thing (distribute routing information), but are considered Aplication Layer protocols, maybe because they rely on transport protocol (TCP) for its connections. Classifying routing protocols in OSI/TCP models is pretty difficult and polemic though.... 

Anyway, I am adding a caputre with OSPF hellos and update (no transport protocol), LDP packets (UDP as tansport transport) and Telnet (TCP as transport protocol) packets. You can look at it with Wireshark and hope it can help you to clarify your doubt

Regards

Joseph W. Doherty
Hall of Fame
Hall of Fame

 ...where does OSPF packet fits in a typical IP packet ?

As also noted by Jon, it's the payload of an IP packet, specifically of a OSPF protocol IP packet.

and since 'OSPF LSA' carries prefix and other info..where does that fit in over all IP Packet concept ?

It doesn't, beyond being one of the defined IP packet protocol types.

I.e. IP, itself, just tells us such a packet is one used by OSPF, it's then up to OSPF to make meaning of the IP packet's payload.

Rolf Fischer
Level 9
Level 9

Hi,

and since 'OSPF LSA' carries prefix and other info..where does that fit in over all IP Packet concept ?

Is there any encapsulation happening here?

This is a very good question!

When designing a large OSPF network, it can be challenging to decide how many routers you want to put in a single OSPF area.

I heard a very interesting advice in a CiscoLive session: 

BRKRST-2337 - OSPF Deployment in Modern Networks (at ~17:30 minutes)

"Keep router LSAs under MTU size - avoid IP fragmentation."

Although IP fragmentation would (of course) work with very large OSPF Router-LSAs, you should avoid it. In simple terms, Router-LSAs carry the link-information of all the router-interfaces in an area (the details are quite complicated). A typical IP-packet sent over Ethernet with 1500 byte MTU would be able to encapsulate a OSPF Router-LSA that describes 119 links without the need for fragmentation. Depending on the type of connections this would typically correspond to ~50 routers.

HTH
Rolf

[EDIT]:

In order to produce a wireshark capture of fragmented OSPF packets I set up a quick lab with a large number of OSPF-enabled loopback interfaces (see attached file).

R1#show ip ospf database

                Router Link States (Area 0)
Link ID         ADV Router      Age         Seq#       Checksum Link count
1.1.1.1         1.1.1.1         347         0x80000010 0x0025B4 120
2.2.2.2         2.2.2.2         515         0x80000002 0x003BF8 1

                Net Link States (Area 0)
Link ID         ADV Router      Age         Seq#       Checksum
192.168.12.1    1.1.1.1         514         0x80000001 0x00C7EB

Depending on the type of connections this would typically correspond to ~50 routers.

For the sake of completeness I want to point out that we're talking about ~50 (up to 118) neighbor-routers, since every router generates a Router-LSA only for its own interfaces in that area. So this is not really the maximum number of routers in an area - its rather the maximum number of neighbors in the same area...

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card