0% found this document useful (0 votes)
6 views

Ospf

Uploaded by

Umamaheswari KM
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Ospf

Uploaded by

Umamaheswari KM
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 24

Two important link state routing protocols:

Open Shortest Path First (OSPF) and

Intermediate System-to-Intermediate System (IS-IS).


• While OSPF is exclusively designed for IP networks,
• IS-IS was designed for the connection-less network protocol (CLNP) in
the OSI reference model
• an integrated IS-IS or dual IS-IS protocol has been used to support
both CLNP and IP
• there are no fundamental differences between OSPF and IS-IS
• OSPF is an instance of a link state protocol based on hop-by-hop
communication of routing information,
• specifically designed for intra domain routing in an IP network.
• a routing protocol requires information about the state (e.g., cost) of
a link, and the ability to advertise this link state reliably through in-
band (in-network) communication.
• Furthermore, a link state protocol uses two sub protocols, one to
establish a neighbourhood relationship through a hello protocol, and
another for database synchronization
• an instance applicable in a specific networking environment requires
certain customization, including provision for flexibility to handle
various possible variations
OSPF: Protocol Features

Network Hierarchy

• OSPF provides the functionality to divide an intra domain network (an autonomous system) into
subdomains, commonly referred to as areas. Every intra domain must have a core area, referred
to as a backbone area; this is identified with Area ID 0. Areas are identified through a 32-bit area
field; thus Area ID 0 is the same as 0.0.0.0.

• Usually, areas (other than the backbone) are sequentially numbered as Area 1 (i.e., 0.0.0.1), Area
2, and so on. OSPF allows a hierarchical setup with the backbone area as the top level while all
other areas, connected to the backbone area, are referred to as low-level areas; this also means
that the backbone area is in charge of summarizing the topology of one area to another area, and
vice versa.
• Router Classification
• the routers are classified into four different types :
• Area-Border Routers: These are the routers that sit on the border between the
backbone and the low-level areas. Each area-border router must have at least one
interface to the backbone; it also has at least one interface to each area to which it is
connected.
• Internal Routers: These are the routers in each low-level area that have interfaces only
to other internal routers in the same area.
• Backbone Routers: These are the routers located in Area 0 with at least one interface to
other routers in the backbone. Area-border routers can also be considered as backbone
routers.
• AS Boundary Routers: These routers are located in Area 0 with connectivity to other AS;
they must be able to handle more than one routing protocol. For example, to exchange
information with another AS, they must be able to speak BGP. These routers also have
internal interfaces for connectivity to other backbone routers.
• The above terminologies, as described, are OSPF specific; however, it is also common to
use names such as backbone routers in general
• Network Types
OSPF is designed to address five different types of networks:
(1) point-to-point networks,
(2) broadcast networks,
(3) Non broadcast multi access (NBMA) networks,
(4) point-to-multi-point networks, and
(5) virtual links.
• Point-to-point networks refer to connecting a pair of routers directly by an interface/link such as OC-3. A router may be connected to
multiple different routers by such point-to-point interfaces. Point-to-point links are typically used when an OSPF domain is spread out in a
geographically distributed region.
• Broadcast networks refer to networks such as LANs connected by a technology such as Ethernet. Broadcast networks, by nature, are multi
access where all routers in a broadcast network can receive a single transmitted packet. In such networks, a router is elected as a
Designated Router (DR) and another as a Backup Designated Router (BDR).
• Non broadcast multi access networks use technologies such as ATM or frame relay where more than two routers may be connected
without broadcast capability. Thus, an OSPF packet is required to be explicitly transmitted to each router in the network. Such networks
require an extra configuration to emulate the operation of OSPF on a broadcast network. Like broad-cast networks, NBMA networks elect a
DR and a BDR.
• Point-to-multipoint networks are also non broadcast networks much like NBMA networks; however, OSPFÕs mode of operation is different
and is in fact similar to point-to-point links.
• Virtual links are used to connect an area to the backbone using a non backbone (transit) area. Virtual links are configured between two
area-border routers. Virtual links can also be used if a backbone is partitioned into two parts due to a link failure; in such a case, virtual
links are tunnelled through a non backbone area. Consider again Figure 6.1. Here Area 3 is connected to the backbone area using transit
Area 2 through a virtual link that connects router 6 to router 7. Also note that if the link between router 2 and router 3 in the backbone
area goes down, Area 0 becomes partitioned; to avoid that, a virtual link between Area-Border Routers 4 and 5 is established through Area
1.
• Finally, an important point to understand about OSPF networks is that the neighborhood relation is not based on routers or networks
connected by physical links, but is based on logical adjacencies established.
Flooding : -
• OSPF uses in-network functionality to flood routing information such as LSAs. In-network means
OSPF packets are carried in the same network as user traffic. From the discussion above, we note
that there are different possible network types. Thus, transmission of OSPF packets requires some
tailoring.
• First note that multiple LSAs can be combined into an OSPF link state update packet. Flooding is
required for link state update packets, as well as for LSA packets the protocol type field in an IP
packet header is set to 89 for OSPF packets. Also note that flooding is selective in that a router
forwards an update only if it is not stale; for this, it relies on checking the age and the sequence
number field
• On point-to-point networks, updates use the IP multicast address 224.0.0.5, referred to as AllSPF
Routers. A router on receiving an update forwards it to other routers, if needed (after checking
the sequence number), again using the same multicast address.
• On broadcast networks, all non-DR and non-BDR routers send link state update and LSA packets
using the IP multicast address 224.0.0.6, referred to as AllD Routers. Any OSPF packets that
originates from a DR or a BDR, however, use the IP multicast address 224.0.0.5.
• In NBMA networks, LSAs are sent as unicast from non-DR/non-BDR routers to the DR and the
BDR. DR, in turn, sends a copy of the LSA as unicast to all adjacent neighbours. On point-to-
multipoint networks and virtual link networks, updates are sent as unicast using the interface’s IP
address of the adjacent neighbour.
• OSPF flooding must be reliable.
• Since OSPF sits directly on top of IP in the TCP/IP stack, OSPF is required
to provide its own reliable mechanism, instead of being able to use a
reliable transport protocol such as TCP.
• OSPF addresses reliable delivery of packets through use of either
implicit or explicit acknowledgment.
• An implicit acknowledgment means that a duplicate of the LSA as an
update is sent back to the router from which it has received the update.
• An explicit acknowledgment means that the receiving router sends a
LSA packet on receiving a link state update
OSPF defines three global parameters in regard to flooding of LSAs:
LS Refresh-Time indicates the maximum acceptable time between
generation of any particular LSA, regardless of whether the content of
the LSA such as the metric value has changed; this time window is set
to 30 min.
MinLSInterval - reflects the minimum time between generation of any
particular LSA; this is set to 5 sec.
MinLSArrival - is the minimum time between reception of new LSAs
during flooding, set to 1 sec; this parameter serves as the hold-down
timer.
Link State Advertisement Types
• From the discussion about network hierarchy and network types, it is clear that an OSPF network
requires different LSA types.
• The five most commonly known LSA types are:
A Router LSA is the most Router LSA (type code = 1),
Network LSA (type code = 2),
Network Summary LSA (type code = 3),
AS Border Router (ASBR) Summary LSA (type code = 4), and
AS External LSA (type code = 5).
• basic or fundamental LSA that is generated for each interface. Such LSAs are generated for point-to-
point links.
• Router LSAs are recorded in the link state database and are used by the routing computation module.
Flooding of Router LSAs is restricted to the area where they originate.
• Network LSAs are applicable in multi access networks where they are generated by the DR. All attached
routers and the DR are listed in the Network LSA. Flooding of Network LSAs is also restricted to the
area where they originate.
• Area-Border Routers generate Network Summary LSAs that are used for advertising destinations
outside an area. In other words, Network Summary LSAs allow advertising IP prefixes between areas.
Area Border Routers also generate ASBR Summary LSAs; in this case, they advertise AS Border Routers
external to an area.
• AS External LSAs are generated by AS Border Routers. Destinations external to an OSPF AS are
advertised using AS external LSAs.
Sub protocols :-
Sub protocol mechanisms are also used for the operation of a link state protocol in addition to
the main function of LSA through flooding.
Two key sub protocols are
the hello protocol and
the data-base synchronization protocol.
HELLO PROTOCOL :
• hello protocol is just for initialization
• hello protocol is used for neighbour discovery as well as to agree on several parameters
before two routers become neighbours
DATABASE SYNCHRONIZATION PROCESS:
• Beyond basic initialization to discover neighbours, two adjacent routers need to build
adjacencies.
• This is important more so after a failed link is recovered between two neighbouring routers.
• Since the link state database maintained by these two routers may become out of sync
during the time the link was down, it is necessary to synchronize them again
Routing Computation and Equal-Cost Multipath : -
An important feature of OSPF routing computation is the equal-cost
multipath (ECMP) option;
that is, if two paths have the same lowest cost, then the outgoing link
(next hop) for both can be listed in the routing table so that traffic can
be equally split.
It may be noted the original Dijkstra’s algorithm generates only one
shortest path even if multiple shortest paths are available.
To capture multiple shortest paths, where available, Dijkstra’s algorithm
is slightly modified
Additional Features
• OSPF has the capability to authenticate packet exchanges between
two routers. Such authentication can be either simplex password-
based or MD5-based.
• Furthermore, extensions to OSPF, to add digital signature
authentication to LSA data and to provide a certification mechanism
for router data
1. STUB AREAS AND STUB NETWORKS
2. ADDITIONAL LSA TYPES
3. ROUTE REDISTRIBUTION
OSPF packet header
COMMON HEADER
The common header has the following key fields :
• Version: This field represents the OSPF version number; the current version is 2.
• Type: This field specifies the type of packet to follow. OSPF has Þve packet types: hello
(1), database description (2), link state request (3), link state update (4), and LSA (5).
• Packet Length: This indicates the length of the OSPF packet.
• Router ID: This field indicates the ID of the originating router. Since a router has
multiple interfaces, there is no definitive way to determine which interface IP address
should be the router ID. According to RFC 2328 [505], it could be either the largest or
the smallest IP address among all the interfaces.
• Area ID: This is the ID of the area where the OSPF packet originated. Value 0.0.0.0 is
re-served for the backbone area.
• Checksum: This is the IP checksum over the entire OSPF packet.
• AuType and Authentication Field: AuType works with the Authentication field for
authentication.
OSPF hello packet
The primary purpose of the hello packet is to establish and maintain adjacencies. This means that it
maintains a link with a neighbour that is operational. The hello packet is also used in the election process of
the DR and BDR in broadcast networks. The hello packet is also used for negotiating optional capabilities.
• Network Mask: This is the address mask of the router interface from which this packet is sent.
• Hello Interval: This field designates the time difference in seconds between any two hello packets. The
sending and the receiving routers are required to maintain the same value; otherwise, a neighbour
relationship between these two routers is not established. For point-to-point and broadcast networks, the
default value is 10 sec, while for non broadcast net-work the default value used is 30 sec.
• Options: Options field allows compatibility with a neighbouring router to be checked.
• Priority: This field is used when electing the designated router and the backup designated router.
• Router Dead Interval: This is the length of time in which a router will declare a neighbour to be dead if it
does not receive a hello packet. This interval needs to be larger than the hello interval
• Designated Router (DR) (Backup Designated Router (BDR)): DR (BDR) field lists the IP ad-dress of the
interface of the DR (BDR) on the network, but not its router ID. If the DR (BDR) field is 0.0.0.0, then this
means there is no DR (BDR).
• Neighbor: This field is repeated for each router from which the originating router has received a valid
Hello recently, meaning in the past Router Dead Interval.

DATABASE DESCRIPTION PACKET
The OSPF database description packet has the following key features :
• Interface Maximum Transmission Unit (MTU): This field indicates the
size of the largest transmission unit the interface can handle without
fragmentation.
• Options: Options fields consist of several bit-level fields. The most
critical one is the E-bit, which is set when the attached area is capable
of processing AS-external LSAs.
• I/M/MS bits: I-bit (initial-bit) is initialized to 1 for the initial packet
that starts a database description session; for other packets for the
same session, this field is set to 0. M-bit (more-bit) is used to indicate
that this packet is not the last packet for the database description
session by setting it to 1; the last packet for this session is set to 0. MS
bit is used to indicate that the originator is the master by setting this
Þeld to 1, while the slave sets this Þeld to 0.
• DD Sequence number: This field is used for incrementing the
sequence numbers of packets from the side of the master during a
database description session; the master sets the initial value for the
sequence number.

• LSA Header: This field lists headers of the LSAs in the originator’s link
state database; it may list some or all of them.
LINK STATE REQUEST PACKET
The link state request packet is used for pulling information.
Link State Type: This field identifies a link state type such as a router or
network
• Link State ID: This Þeld is dictated by the link state type.
• Advertising Router: This is the address of the router that has generated
this LSA.
LINK STATE UPDATE PACKET
• This packet contains the first field to be the number of LSAs followed by
information on LSAs that follow the LSA packet format. Thus, a link state
update packet can contain one or more LSAs.
LINK STATE ACKNOWLEDGMENT PACKET
• The LSA packet is used in acknowledging each link state advertisement
received from a neighboring router. This includes the LSA headers that
follow the OSPF packet header where the type Þeld is set to 5.
Link state update packet

You might also like