You are on page 1of 5

CN-LAB ASSIGNMENT

ROLL NO.- 2022BCS035


NAME- KANAK DHIMAN

OPEN SHORTEST PATH FIRST(OSPF) PROTOCOL


Open Shortest Path First (OSPF) is a link-state routing protocol that is used to find the best
path between the source and the destination router using its own Shortest Path First). OSPF
is developed by Internet Engineering Task Force (IETF) as one of the Interior Gateway
Protocol (IGP), i.e., the protocol which aims at moving the packet within a large
autonomous system or routing domain. It is a network layer protocol which works on
protocol number 89 and uses AD value 110. OSPF uses multicast address 224.0.0.5 for
normal communication and 224.0.0.6 for update to designated router (DR)/Backup
Designated Router (BDR).

Key terms:
1. Router Id – It is the highest active IP address present on the router. First, the
highest loopback address is considered. If no loopback is configured, then the
highest active IP address on the interface of the router is considered.
2. Router priority – It is an 8-bit value assigned to a router operating OSPF, used
to elect DR and BDR in a broadcast network.
3. Designated Router (DR) – It is elected to minimize the number of adjacencies
formed. DR distributes the LSAs to all the other routers. DR is elected in a
broadcast network to which all the other routers share their DBD. In a broadcast
network, the router requests for an update to DR, and DR will respond to that
request with an update.
4. Backup Designated Router (BDR) – BDR is a backup to DR in a broadcast
network. When DR goes down, BDR becomes DR and performs its functions.
5. DR and BDR election – DR and BDR election takes place in the broadcast
network or multi-access network. Here are the criteria for the election:
 The router having the highest router priority will be declared as DR.
 If there is a tie in router priority, then the highest router I’d be
considered. First, the highest loopback address is considered. If no
loopback is configured, then the highest active IP address on the
interface of the router is considered.

USES AND APPLICATION OF OSPF: -


1. ROUTING WITHIN AUTONOMOUS SYSTEMS: OSPF is primarily used within an
autonomous system (AS), which is a collection of IP networks and routers under a
common administration sharing a common routing strategy. OSPF enables routers
within an as to exchange routing information and dynamically adjust to changes in
the network topology.
2. EFFICIENT ROUTING: OSPF calculates the shortest path between routers based on
metrics such as cost (which is typically based on link bandwidth). By finding the
shortest path, OSPF ensures efficient routing of IP packets, reducing network
congestion and improving overall network performance.
3. INTERNET SERVICE PROVIDERS (ISPS): OSPF is extensively used by ISPS to manage
the routing of traffic between their various points of presence (pops), backbone
networks, and customer networks. It allows ISPS to efficiently route traffic across
their networks while adapting to changes in network topology and ensuring high
reliability and performance.
4. CAMPUS NETWORKS: OSPF is utilized in campus networks found in universities,
large corporations, and government institutions. It helps connect various buildings,
departments, and facilities within the campus while providing fast and reliable
routing of traffic. OSPF hierarchical design allows campus networks to scale
effectively and support many network devices.

IMPLEMENTATION USING CISCO:

CONFIGURE THE PC0 AND PC1:

 IP ADDRESS :192.168.1.2
 SUBNET MASK:255.255.255.0
 DEFAULT GATEWAY: 192.168.1.1
 IP ADDRESS:192.168.2.2
 SUBNET MASK:255.255.255.0
 DEFAULT GATEWAY: 192.168.2.1
Config the router0 and router2:
 IP ADDRESS :192.168.1.1
 SUBNET MASK:255.255.255.0
 IP ADDRESS :192.168.2.1
 SUBNET MASK:255.255.255.0
Now config the serial port for all routers as shown in figure

Configure the Router0 and create router OSPF 1 and then add network id with
wildcard mask.
Router(config)#router ospf 1
Router(config-router) #network 192.168.1.0 0.0.0.255 area 0
Router(config-router) #network 10.0.0.0 0.255.255.255 area 0
Router(config-router) #network 20.0.0.0 0.255.255.255 area 0
Configure the Router1 and create router OSPF 1 and then add network id with
wildcard mask.
Router(config)#router ospf 1
Router(config-router) #network 10.0.0.0 0.255.255.255 area 0
Router(config-router) #network 20.0.0.0 0.255.255.255 area 0
Configure the Router2 and create router OSPF 1 and then add network id with
wildcard mask.
Router(config)#router ospf 1
Router(config-router) #network 192.168.2.0 0.0.0.255 area 0
Router(config-router) #network 20.0.0.0 0.255.255.255 area 0
Router(config-router) #network 30.0.0.0 0.255.255.255 area 0

You might also like