cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2070
Views
0
Helpful
3
Replies

OSPF network type VS link type, please help me

rookie R
Level 1
Level 1

Hi!

When I study the knowledge about OSPF, I found that there are two terms, 'network type' and 'link type'.
There are three kinds of network type: Point-to-point networks, Broadcast networks and Non-broadcast networks.
The link type is a field called ‘Type’ at LSA Type 1:

Snipaste_2020-08-05_16-14-14.jpg

Snipaste_2020-07-21_17-02-14.jpg

as far as I can tell, the network type decides the subnet mask of the interface in the routing table, for example, if you change the network type of a loopback interface form loopback to p2p, the subnet mask of that interface changes from 32/ to 24/ in the routing table;the link type decide the use of memory requirements, for example, if an interface's link type is 'connection to a transit network' , it requires more memory than 'connection to a stub ' , because the stub network is not in the "from" rows of the adjacency matrix.

Is my understanding correct? I think I didn't get these things thoroughly

 

1 Accepted Solution

Accepted Solutions

Martin L
VIP
VIP

 

Critical OSPF network type is determined based on physical link type; it is per-defined based on encapsulation like Ethernet or PPP or ATM/Frame relay.  so, P2p Network type will be determined if you have PPP or HDLC set on the interface. Broadcast network type is automatically set up on every Ethernet, Fast Ethernet, and Gigabits interfaces.   The most challenging type was NBMA like Frame Relay;  RFC defines only nonbroadcast and point to mulitpoint; Cisco has added 3: p2p, broadcast, and point to mulitpoint nonbroadcast.  Fortunately, FR is gone from exams and almost gone real-world setups.

network type of a loopback - as you noted - is a special one; Loopback is considered as Stub network; while virtual link is special type: virtual link.

In order to run algorithm and build SPF database, each router advertised its own links in LSA type 1. This is needed to describe the states of router's links (aka a role of la ink).  Types are:

1- P2P link where there is a router but no DR/BDR (neighbor router ID)

2- Transit network connection is defined as link with DR/BDR (DR's IP)

3- Stub network is a connection with no other router on that link, aka dead-end link (network/subnet ID)

4- Virtual link is special one (neighbor router ID)

Note: Each of those link types includes link ID which helps to identify what is on the other end of link: router ID or network/subnet id.  I added those in parenthesis 

 

Regards, ML
**Please Rate All Helpful Responses **

 

View solution in original post

3 Replies 3

Giuseppe Larosa
Hall of Fame
Hall of Fame

Hello @rookie R ,

in OSPF the network type determines the behaviour of the router and the adjacent nodes on the common segment the most important aspect is when a Designated Router DR and Backup DR BDR are elected or not.

There are several network types with their own properties.

Another parameter influenced by network type is hello timer and dead interval timer (10s/40s on broadcast and p2p 30s/120s on NBMA and point to multipoint and point to multipoint non-broadcast)

 

The link type simply tells if there are other OSPF routers on the link = transit network , a single neighbor p2p or no neighbor at all stub. Depending on the link type the other parameters in the Link data are filled.

For example in a transit network of type broadcast there is a reference to the DR address on the segment.

 

For loopbacks the use of network type p2p is a trick to be able to advertise loopbacks with prefix lengths different from host /32 otherwise as you noted a /32 is advertised.

 

Hope to help

Giuseppe

 

Martin L
VIP
VIP

 

Critical OSPF network type is determined based on physical link type; it is per-defined based on encapsulation like Ethernet or PPP or ATM/Frame relay.  so, P2p Network type will be determined if you have PPP or HDLC set on the interface. Broadcast network type is automatically set up on every Ethernet, Fast Ethernet, and Gigabits interfaces.   The most challenging type was NBMA like Frame Relay;  RFC defines only nonbroadcast and point to mulitpoint; Cisco has added 3: p2p, broadcast, and point to mulitpoint nonbroadcast.  Fortunately, FR is gone from exams and almost gone real-world setups.

network type of a loopback - as you noted - is a special one; Loopback is considered as Stub network; while virtual link is special type: virtual link.

In order to run algorithm and build SPF database, each router advertised its own links in LSA type 1. This is needed to describe the states of router's links (aka a role of la ink).  Types are:

1- P2P link where there is a router but no DR/BDR (neighbor router ID)

2- Transit network connection is defined as link with DR/BDR (DR's IP)

3- Stub network is a connection with no other router on that link, aka dead-end link (network/subnet ID)

4- Virtual link is special one (neighbor router ID)

Note: Each of those link types includes link ID which helps to identify what is on the other end of link: router ID or network/subnet id.  I added those in parenthesis 

 

Regards, ML
**Please Rate All Helpful Responses **

 

Martin L
VIP
VIP

 

when I changed loopback from type loopback to p2p, router still shows loopback as "stub" as it was before; So, besides network mask change, there is no other change.  OSPF data base showed same number of links after  and before.  I don't think router memory is affected here.

in case of DR/BDR elections on Network type, thee might be slight memory increase due to the fact that those elections must happen. Also, each router would have to keep multiple adjacency to others and exchange info with others.  While, once DR is elected, its role is to update others.  So, on any Ethernet networks with only 2 OSPF routers, it is recommended to change network type to p2p.

 

Number of Links: 3  
Link connected to: a Stub Network
     (Link ID) Network/subnet number: 1.1.1.1
     (Link Data) Network Mask: 255.255.255.255
      Number of TOS metrics: 0
       TOS 0 Metrics: 1

***** and after ***
 Number of Links: 3
    Link connected to: a Stub Network
     (Link ID) Network/subnet number: 1.1.1.0
     (Link Data) Network Mask: 255.255.255.0
      Number of TOS metrics: 0
       TOS 0 Metrics: 1

The most "weird" thing is that each serial interface or link will have 2 entries in database: 1 as p2p and 2nd one as stub

 Number of Links: 5
    Link connected to: another Router (point-to-point)
     (Link ID) Neighboring Router ID: 2.2.2.2
     (Link Data) Router Interface address: 192.168.1.1
      Number of TOS metrics: 0
       TOS 0 Metrics: 64

    Link connected to: a Stub Network
     (Link ID) Network/subnet number: 192.168.1.0
     (Link Data) Network Mask: 255.255.255.252
      Number of TOS metrics: 0
       TOS 0 Metrics: 64

So, one would say "avoid using serial links to reduce database size"

Furthermore, changing Ethernet link from broadcast to p2p, added 1 more entry in database same as it was in case of serial links.  so, it feels like "no win" situation.

Number of Links: 6
 Link connected to: another Router (point-to-point)
     (Link ID) Neighboring Router ID: 2.2.2.2
     (Link Data) Router Interface address: 10.0.0.1
      Number of TOS metrics: 0
       TOS 0 Metrics: 5
          
    Link connected to: a Stub Network
     (Link ID) Network/subnet number: 10.0.0.0
     (Link Data) Network Mask: 255.255.255.0
      Number of TOS metrics: 0
       TOS 0 Metrics: 5

 

 

Regards, ML
**Please Rate All Helpful Responses **

Review Cisco Networking for a $25 gift card