Thursday, 11 April 2019

OSPF Series 1: OSPF Introduction, and Different OSPF Packet Types and Formats

OSPF Introduction:

  • OSPF RFC- 2328 https://www.ietf.org/rfc/rfc2328.txt
  • To start the OSPF connection, we only need the directly connected connection .ie. only to the neighbour on the same network
  • So, on both the routers, we should run #network 10.0.0.1/24 and on the other #network 10.0.0.2/24 .
    • img

OSPF PACKET TYPES:

  • OSPF Packet Header:

  1. None (0): No authentication
  2. Clear Text (1): Passwords are exchanged as plain text
  3. MD5 (2): encrypted with a key that is shared with partner
    • Authentication: 64 bit field carrying the password
  • OSPF Hello Packet:

    • http://www.freesoft.org/CIE/RFC/1583/104.htm

    • Note that the active neighbour field can have any number of neighbour Router IDs to which it is connected to.

    • The default OSPF hello time is 10 seconds and the dead interval is 40 seconds. (Hello time is configurable whereas DeadTimer is always 4 times hello time)

    • The TTL in IP header of OSPF is 1, so that it is advertised only to the immediate neighbour

  • OSPF Database Description Packet:

    • Interface MTU:

      • The size in bytes of the largest IP datagram that can be sent out the associated interface, without fragmentation.
    • DD Sequence:

      • The topology change is notified via the DD packet. The DD packet is divided into segments by the master and sent to the slaves.
      • Master sends a DB packet to slave (let seq. No be 1). If the slave receives it, it sends an DB back to master with seq. No 1. The master then increments the sequence number by 1 and sends the DD packet that has sequence number 2.
      • Note that the slave does not increase the sequence number. DD sequence number is incremented only by the master.
    • Init Bit:

      • If it is set, it means it is the first packet. It says not initialised.
    • Master Bit:

      • Initially, every router will set master bit as 1. But, the router that has higher router ID will become the master.
      • The slaves will send DB with this bit as ‘0’
    • Link State Advertisement Header:

      • It contains the router ID of the sender router to which Link State Requests are sent.
  • OSPF Link State Request:

    • After exchanging Database Description packets with a neighboring router, a router may find that parts of its link-state database are out-of-date. The Link State Request packet is used to request the pieces of the neighbor’s database that are more up-to-date. Multiple Link State Request packets may need to be used.

    • A router that sends a Link State Request packet has in mind the precise instance of the database pieces it is requesting. Each instance is defined by its LS sequence number, LS checksum, and LS age

  • OSPF Link State Update Packet:

    •  

       

  • OSPF Link State Acknowledgement Packet:

No comments:

Post a Comment