• What are the steps of becoming OSPF neighbors and exchanging routes?
    • If Hello parameters match routers will elect Master/Slave (better RID)
    • Master will send it’s DBD then Slave
    • Routers compare their DBD and if one of them has a missing route it send Link State Request. The neighbor sends the route in a Link State Update.
    • When the DBD match they neighborship state will become FULL
      neighborship-states.PNG
      (An LSU  contains one or more Link State Advertisement)
  • What is the point of DR/BDR? How is a new routing update propagated in the OSPF network?
    • A separate DR/BDR is chosen on every LAN (every router interface). It is needed to control the advertisement. In case of a full mesh OSPF LAN every device would flood the newly received advertisement.
    • When an OSPF device receives a new LSA, it will flood it on all it’s interfaces (except where received) using the 224.0.0.6 (dr/bdr-routers) multicast group.
      This way the DR and BDR devices receive the new route. After that the DR will flood the LSA to the 224.0.0.5 (all-spf routers) multicast group.
      dr-bdr.jpg
  • How does OSPF routers choose DR and BDR?
    • there will be 1 DR and 1 BDR in a subnet
    • the router with the highest priority win (if tied highest RID)
      • (interface) ip ospf priority value
    • after DR and BDR choosen, there will be no change (even if better priority router connects)
    • If DR fail BDR will be the DR. If both of them fails there will be a new election.
  • You don’t want to use BDR in your segment (ie frame-relay). How do you achive this?
    • set the ospf priority to 0 on all non-DR
  • Which device will be the DR and which the BDR in a P2P network?
    • there will be no DR/BDR

lsa-types.PNG

  • Describe LSA Type 1 (Router LSA)
    • Router Link States (Area 20)
      
      Link ID ADV Router Age Seq# Checksum Link count
      4.4.4.4 4.4.4.4 368 0x80000001 0x0067DB 2
      5.5.5.5 5.5.5.5 366 0x80000002 0x00011A 3
    • each router creates a type 1 LSA and floods in the area
    • Do not leave the area
    • Verify:
      • show ip ospf database 
      • show ip ospf database router IP
  • Describe LSA Type 2 (Net Link LSA)
    • Only DR routers send Type 2 LSA for the subnet (where they are DR).
        Net Link States (Area 30)
      
      Link ID ADV Router Age Seq# Checksum
      10.0.0.18 6.6.6.6 872 0x80000001 0x006973

      The Link ID is the IP address of the network’s DR.
      (Careful: PPP interface do not have DR/BDR)

    • Verify:
      • show ip ospf database 
      • show ip ospf database network IP
  • Describe LSA Type 3 (Summary LSA)
    •  Summary Net Link States (Area 20)
      
      Link ID ADV Router Age Seq# Checksum
      1.1.1.1 4.4.4.4 61 0x80000001 0x00F630
      3.3.3.3 4.4.4.4 61 0x80000001 0x00A479
      8.8.8.8 4.4.4.4 61 0x80000001 0x00C741
    • ABR do not forward type 1 and type 2 between areas but summarizes them as Type 3 LSA.
    • The ABR assigns an LSID of the subnet address being advertised and also adds its own RID to the LSA, so that routers know which ABR advertised the route. This is needed so the below topology (2 ABR for 1 external route) is viable. type-3-lsa.PNG
  • Describe LSA Type 4 (Summary ASBR LSA)
    • Type 4 LSA advertises information about how to reach an autonomous
      system boundary router (ASBR) to routers in a different area than the
      ASBR.
    •  Summary ASB Link States (Area 20)
      
      Link ID ADV Router Age Seq# Checksum
      1.1.1.1 4.4.4.4 746 0x80000001 0x00DE48
      2.2.2.2 4.4.4.4 747 0x80000001 0x00BA67
      3.3.3.3 4.4.4.4 747 0x80000001 0x008C91
      7.7.7.7 4.4.4.4 747 0x80000001 0x00D33A
  • Describe LSA Type 5  (Type-5 AS External Link LSA)
  • How do you limit the number of LSAs that a router can learn?
    • ospf subcommand: max-lsa number

The Database Exchange Process

  • What is a DD or DBD?
    • Database Description: exchange a brief version of each LSA so that a router knows a list of that neighbor’s known LSAs
  • What OSPF states do you know?ospf-states.png
  • How does the neighbor initialization start?neigbhor-init.PNG
  • What happens when the router reaches 2-Way state?
    • It decides if it should exchange the LSDB entries.
      If no DR exist then the router will always exchange!
  • How does the Database Exchange process work?
    • db-exchange.PNG
  • Which router will be the Master and which the Slave?
    • The one with the higher RID is the Master.
  • What do the DD messages contain?
    • LSA headers which include the LSID and the LSA sequence number (hexa)
  • What is the state called when the routers send LSR LSU ? How do they ackknowledge a LSU?
    • the state is Loading
    • acknowledge with LSAck packet or by sending back the LSA in an LSU
  • What multicast IP is used for all SFP routers and what for DR/BDR routers?
    • all SFP: 224.0.0.5
    • DR/BDR: 224.0.0.6
  • How does LSDB exchanges when there is a DR/BDR in the network?
    • The non-DR routers (DROther) perform database exchange with the 224.0.0.6 all-DR-routers multicast address (the BDR also hears and processes these messages but silently)
    • After this the DR will flood the new LSAs (only the new) to 224.0.0.5 all-SFP multicast address
  • What happens when an OSPF router joins to an area (R1)?flooding.PNG
    • R2 will learn R1’s Type1 LSAs then it will flood its DD to the DR router on R2/R3/R4 LAN. This way R3 and R4 will learn the new routes.
  • What is periodic flooding and why it is needed?
    • Every LSA has an age (3600 sec maximum). When received it is set to 0 and counts. When reaches 30 minutes and no changes were done it will set the timer to zero and refloods the LSA.
  • How does OSPF flushes an LSA from LSDB?
    • It sets the LSAge to 30 minutes and refloods the LSA. The receiving routers will realize that the age has reached the maximum and will remove the LSA from LSDB.

Choosing the Best OSPF Routes

  • How does OPSF calculate interarea routes?
    • Collects all Type1 and Type2 LSAs to find all subnets in the area.
    • Calculates all routes and picking the lowest-total-cost
  • What if metric tie?
    • OSPF uses equal path load balancing (but not unequal cost load balancing)
    • by default maximum-paths 4
  • What kind of information does Type 3 LSA have?
    • the subnet number/mask represented by LSA
    • the cost of the ABR’s lowest-cost route to reach the subnet
    • the RID of the ABR
  • How does the routers calculates cost for an interarea route?
    • calculate the intra-area cost to the ABR listed in the Type 3 LSA
    • add the cost value listed in the Type 3 LSA
  • How do you recognize an interarea route?
    • show ip route ospf  O IA
      This means that the route is learned from a Type 3 LSA.
  • Which route would R1 choose and why?
    interarea-intraarea

    • it will choose the intraarea route to Area 0
    • Intraarea routes are always better regardless the metric!
    • If an ABR learns a Type 3 LSA inside a nonebackbone area, the ABR ignores that LSA when calculating its own routes.
  • What happens when an intra-area route changes (Type1-2 LSA) ?
    • SFP recalculates the metric
  • What happens when an interarea router changes (Type 3 LSA) ?
    • SFP does not recalculate because Type 3 LSA do not actually describe the topology
  • How does OSPF calculate default cost?
    • Cost = Reference-Bandwidth / Interface-Bandwidth
  • What is the default Reference-Bandwidth and how do you modify it?
    • 100 Mbit
    • auto-cost reference-bandwidth value
  • What is the cost of a FastEthernet interface (using default settings)?
    • 100 mbps / 100 mbps = 1
  • What is the problem with Gigabit and TenGigabit interfaces?
    • The minimum cost is 1, so a 10Gig interface cost will be the same as a FastEthernet:
      100 mbps / 10,000 mbps = 0,01  –>  1
  • How do you solve this problem?
    • By increasing the reference bandwidth ie.:
      auto-cost reference-bandwidth 1000
  • What else methods do you know to control the cost?
    • by setting the bandwidth interface subcommand (affecting the above formula)
    • or by using the ip ospf cost value command (affecting the cost itself)
  • How do you verify OSPF cost?
    • The best is: show ip ospf interface brief
Advertisements