OSPF is a Link State routing protocol that calls for the sending of link-state advertisements (LSAs) to all other routers within the same hierarchical area. Information on attached interfaces, metrics used, and other variables is included in OSPF LSAs. As OSPF routers accumulate link-state information, they use the SPF algorithm to calculate the shortest path to each node.
As a Link State routing protocol, OSPF contrasts with RIP and IGRP, which are Distance Vector routing protocols. Routers running the Distance Vector algorithm send all or a portion of their routing tables in routing-update messages to their neighbors .
The LSA’s are :
1. LSA Type 1 = Router = Each router creates its own Type 1 LSA for each area it connect. Listing the RID and all interfaces IP addresses on that router .
2. LSA Type 2 = Network = One per transit network created by the DR on the Subnet.
3. LSA Type 3 = Net Summary = Created by ABRs that represent subnets listed in one area’s Type 1 and 2 LSAwhen byeing advertised into another Area .Define the Subnets and the Cost .
4. LSA Type 4 = ASBR Summury = Like Type 3 but advertises a host route used to reach an ASBR ( is to provide route information to an area that does not have a route to the ASBR and originate from ABRs )
5. LSA Type 5 = AS External = Created by ASBRs for external route injected into OSPF
6. LSA Type 6 = Group Membership = Define for MOSPF ( not supported by CISCO )
7. LSA Type 7 = NSSA External = Created by ASBRs inside an NSSA area instead of a Type 5 LSA
8. LSA Type 8 = Links LSAs = Exist only on local link used to advertise the router link-local address to all routers on the same link and provide all IPV6 addresses associated with the link.
9. LSA Type 9 = Intra-Area Prefix LSAs = Can send information about IPV6 Networks including stub networks.
10. Lsa Type 10 = Opaque = For future extentions , has been adapted for MPLS traffic engineering.
LSA Type 1
Each router create a LSA Type 1 base on the RID . Then it flood The LSA to its neighbors in the same area until every router in the same area have a copyof the LSA.
For each interface on which no DR has been elected , it list the routers interface subnet number/mask and interface OSPF Cost. ( Stub network )
For each interface on which a DR has been elected , it list the ip address of the DR and a notation of the link attaches to a transit network ( Type 2 LSAs )
For each interface with no DR but for which a neighbor is reachable , it list the neighbor RID.