Attributes that have to match to successful establish FULL neighbor adjacency

  1. Area ID
  2. Authentication
  3. Subnet/Subnet Mask
  4. Hello/Dead Interval
  5. Stub area flag

 Note: FULL neighbor adjacency state doesn’t mean that LS exchange will take place. There is one additional condition that needs to be met. You can mix network types until they will match DR/BDR election process. So you can mix broadcast and non-broadcast because both network types require DR/BDR election but once you mix broadcast with p2p adjacency will come up but LS exchange will not take place.

Network Type DR H/D Hello Next Hop
broadcast + 10/40 224.0.0.5 ADV R = Originator
non-broadcast + 30/120 unicast ADV R = Originator
point-to-point 10/40 224.0.0.5 connected neighbor
point-to-multipoint 30/120 224.0.0.5 connected neighbor
point-to-multipoint non-broadcast 30/120 unicast connected neighbor

 Multicast IPs

AllSPFRouters – 224.0.0.5 (0100.5e00.0005)

AllDRouters – 224.0.0.6 (0100.5e00.0006)

Router ID Election

  1. Router-id command
  2. Highest IP address on loopback interface
  3. Highest IP address on other interfaces

 DR, BDR Election

  1. The highest priority (255 highest, 0 doesn’t take part in election process)
  2. If tie, highest Router ID

DRothers – established adjacency only with DR, BDR, between DRothers<>DRothers is 2WAY/DRothers

 Interface State Machine

  • Down
  • P2P
  • Waiting
  • DR
  • Backup
  • DRothers
  • Loopback

 Neighbor State Machine

  • Down
  • Attempt (only on NBMA where neighbors are manually configured)
  • Init – Hello has been received but router does not see its own RID in the hello yet
  • 2-Way – router has seen its own RID in the neighbor’s field hello packet (bidirectional)
  • ExStart – neighbor establish master/slave relationship and determine the initial DBD seq number, router with highest RID is master
  • Exchange – router sends DBD packets describing its entire LSDB (LSA Headers), may sends LS Request, requesting more recent LSAs to neighbors
  • Loading – router sends LS Request, requesting more recent LSAs that have been discovered in the Exchange state but have not been received
  • Full – neighbors are fully adjacent

 Building an Adjacency

  • Hello (type 1)
  • DBD (type 2)
    • Just description of LSAs (header is sent)
      • receiving router decides whether it has the latest copy of the LSA in its own DB
    • Flag is sent
      • I bit – first DBD packet sent
      • M bit (more bit) – not last DBD packet, will be more
      • MS bit (Master/Slave bit) – set in DBD packet originated by the Master
      • LS Request (type 3)
      • LS Update (type 4)

 Exstart and Exchange process

  1. Both neighbors claim to me the master
    • sending DD with MS bit set to 1
    • own random strange DB sequence number
  2. Router with lower RID will be slave and replay with DD
    • MS bit = 0
    • DD sequence number set to master’s sequence number
    • Its first (I bit) packet with LSA summaries
  3. Exstart process completed
  4. Exchange process starts
  5. If neighbor (router A) receives LSA that
    • Is not in its own database
    • Or remote neighbor has a more recent copy of known LS
    • The router A place the LSA on the Link State Request List
  6. Router A sends LS Request packet asking for complete copy of the LSA from the List
  7. Remote B router sends LSA Update and adds LSA on Link State Retransmission list
  8. Router A sends back LS ACK acknowledged LSA that received
  9. Router B removes acknowledged LSA from the Link State Retransmission list
  10. Next state
    • If A or B have still entries in Link State Request List > Loading state (Master sends M bit set to zero, Slave ACK with the same sync number and M bit zero)
  11. If A or B have no entries in Link State Request List > Full state

Master controls synchronization process and ensure that only one DD packet is outstanding at a time.

When slave receives DD packet, acknowledges the packet by sending a DD packet with the same sequence number.

If master does not receive acknowledgement within Retransmission Interval, then sends new copy.

Sequence Number – all routers must have an identical sequence number

Age

  • Starts from 1
  • MaxAgeDiff – Maximum Age Difference (15 minutes)
  • Router receives multiple copies of the same LSA with identical Sequence Number but with different age
  • If difference in the age < MaxAgeDiff – original LSA is retained (no flooding)
  • If difference in the age > MaxAgeDiff – new LSA recorded and flooded
  • MaxAge – (60 minutes/3600 sec) – after this time LSA is flushed out from LSD
  • LSARefreshTime (30 minutes/1800 sec) – flooding all LSA to reset MaxAge

Area notation example

Area 271 = Area 0.0.1.15  = 00000000.00000000.00000001.00001111=100001111=271

LSA Types

LSA 1 – O, Router LSA (contain all Link IDs – network),

  • Generated by every router and is local to the area
  • Describes all router interfaces + cost
  • “Routing bit set on this LSA” means that the route to this destination is in RIB
  • show ip ospf database router <router-id>

LSA 2 – O, Network LSA (contain all routers attached to the segment)

  • Generated by DR and is local to the area
  • Lists all attached routers (router ID) including DR
  • show ip ospf database network <IP address of DR>

LSA 3 – O IA, Network Summary LSA (describes network from another Area)

  • Generated by ABR and is propagated between areas
  • Include cost from ABR to network
  • show ip ospf database summary <network_IP>

 LSA 4 – O IA, Summary ASB Link States

  • Generated by the ABR and is propagated between areas
  • Describes RID of the ASBR
  • show ip ospf database asbr-summary

 LSA 5 – O E1, O E2, External Link States

  • Generated by ASBR and is propagated between areas
  • Describes links that are external to the AS
  • show ip ospf database external
  • E1 cost consist of:
    • External metric > show ip ospf database external <Link state ID>
    • Metric to ASBR (Advertising Router=RID) > show ip ospf border-routers
  • E2 cost = External metric > show ip ospf database external <Link state ID>

LSA 7 – O N1, O N2, NSSA External Link States

  • Generated by ASBR into Not-So-Stubby (NSSA) area
  • Describes links that are external to the AS in the NSSA area
  • ABR swap the LSA type 7 to LSA type 5 when sends from NSSA into Area 0
  • show ip ospf database nssa-external
  • N1 cost consist of:
    • External metric show ip ospf database nssa-external <Link state ID>
    • Metric to ASBR (Advertising Router=RID) > show ip ospf border-routers
  • N2 cost = External metric > show ip ospf database nssa-external <Link state ID>

Route selection proces based on the LSA type

O>O IA>O E1>O E2>O N1>O N2

Previous PostNext Post

Dodaj komentarz

Twój adres e-mail nie zostanie opublikowany. Wymagane pola są oznaczone *