Does OSPF exchange routing information with adjacencies only or with all routers?
I was using a SIM that had one router in the middle with three other routers connected to it via serial connections.
*The 'Top' router is connected to the 'Middle router'
The question asked assuming the routers were running OSPF, describe how routing information is exchanged.
I assumed the middle router would exchange information with all three routers, but what about the other routers? The SIM said the right router also exchanges information will all three routers (middle, top, and left). I thought that the right router would only exchange info with the middle.
As far as I know. Only with adjacencies. However those adjacent routers would propagate routing information (LSA: Link State Advertisements) to other neighboring routers on other links.
The following paragraph is from the cisco academy curriculum:
"When a router starts an OSPF routing process on an interface, it sends a Hello packet and continues to send Hellos at regular intervals. The set of rules that govern the exchange of OSPF Hello packets is called the Hello protocol. On multi-access networks, the Hello protocol elects a designated router (DR) and a backup designated router (BDR). The Hello carries information about which all neighbors must agree to form an adjacency and exchange link-state information. On multi-access networks the DR and BDR maintain adjacencies with all other OSPF routers on the network.
Adjacent routers go through a sequence of states. Adjacent routers must be in the full state before routing tables are created and traffic routed. Each router sends link-state advertisements (LSA) in link-state update (LSU) packets. These LSAs describe all of the routers links. Each router that receives an LSA from its neighbor records the LSA in the link-state database. This process is repeated for all routers in the OSPF network.
When the databases are complete, each router uses the SPF algorithm to calculate a loop free logical topology to every known network. The shortest path with the lowest cost is used in building this topology, therefore the best route is selected.
Routing information is now maintained. When there is a change in a link-state, routers use a flooding process to notify other routers on the network about the change. The Hello protocol dead interval provides a simple mechanism for determining that an adjacent neighbor is down."
OSPF uses the 188.8.131.52 and 184.108.40.206 multicast addresses to send LSAs. As you know, routers do not forward broadcast/multicast packets by default. So I assume that the receiving router has to process those LSA packets and resend. So the packets will be decapsulated and encapsulated again throughout the TCP/IP stack. (recreation)
Now, in the case of network changes (a link going up or down). It is obvious that the intermediate router would only recreate the same LSA and send it on other segments to other routers, This is also indicated clearly in the documentation I have at hand. But, in the case of OSPF initialization (when the network is just started) and the whole databases are being rebuilt, I'm not sure wither the router would accumulate all link states on one LSA and send them OR send separated LSAs.