0% found this document useful (0 votes)
2 views7 pages

OSPF -1

Uploaded by

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

OSPF -1

Uploaded by

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

MAHTABPUZESHI

INTRODUCTION

Open Shortest Path First (OSPF) is an IP routing protocol that uses a mathematical

algorithm to calculate the most efficient path to direct traffic on IP networks.

Based on link-state or shortest path first (SPF) technology, OSPF distributes routing

information between routers in a single autonomous system (AS).

This capability differentiates OSPF from older TCP/IP routing protocols, which were

designed for less complex networks than those used today.

OSPF is a link-state routing protocol that sends information about directly connected

links to all the routers in the AS network.

The protocol has a full picture of the network topology, which is shared with all the

routers in an area of the AS to calculate the shortest path to each destination.

1|Page
MAHTABPUZESHI

OSPF CONFIGURATION

Router - 1 Description
#interface ethernet 0/0 To select an interface

#no shutdown To enable the interface

#ip address 10.1.24.1 255.255.255.252 To set ip address

#ip ospf cost To calculate the best routes

#ip ospf priority OSPF interface priority by default is 1

#ip ospf bandwidth To set interface speed

#ip ospf hello-interval To set how often we send the hello packet

#ip ospf dead-interval To set how long we should wait for the hello packet
before we declare the neighbor dead

#ip ospf authentication To enable authentication

#ip ospf authentication-key To set an authentication password

2|Page
MAHTABPUZESHI

#interface loopback 0 To select a loopback

#ip address 100.0.0.1 255.255.255.0 To set an ip address for loopback

#interface loopback 1 Loopback selection

#ip address 100.0.1.1 255.255.255.0 To set an ip address for loopback

#interface loopback 2 Loopback selection

#ip address 100.0.2.1 255.255.255.0 To set an ip address for loopback

#router ospf 1 Enabling OSPF protocol

#router-id 1.1.1.1 To set router-id for this OSPF process

#network 10.1.1.0 0.0.0.3 area 20 Enable routing on an IP network

#network 100.0.0.0 0.0.0.255 area 20 Enable routing on an IP network

#network 100.0.1.0 0.0.0.255 area 20 Enable routing on an IP network

#network 100.0.2.0 0.0.0.255 area 20 Enable routing on an IP network

# log-adjacency-changes To configure the router to send a syslog message when


the state of an ospf neighbor changes

#passive-interface Suppress routing updates on an interface

#redistribute rip Redistribute information from another routing protocol

3|Page
MAHTABPUZESHI

Router - 2 Description
#interface ethernet 0/0 To select an interface

#no shutdown To enable the interface

#ip address 10.1.24.2 255.255.255.252 To set an ip address

#interface ethernet 0/1 To select an interface

#no shutdown To enable the interface

#ip address 10.1.25.2 255.255.255.252 To set an ip address

#interface ethernet 0/2 To select an interface

#no shutdown To enable the interface

#ip address 10.1.12.1 255.255.255.252 To set an ip address

#router ospf 1 Enabling OSPF protocol

#router-id 2.2.2.2 To set router-id for this OSPF process

#network 10.1.24.0 0.0.0.3 area 20 Enable routing on an IP network

#network 10.1.25.0 0.0.0.3 area 20 Enable routing on an IP network

#network 10.1.12.0 0.0.0.3 area 0 Enable routing on an IP network

4|Page
MAHTABPUZESHI

OSPF T-shoot Commands Description


#show ip route ospf Display ospf routing table

#show ip ospf neighbor Display the neighbor details

#show ip ospf database Display a list of LSA

#show ip ospf interface Display interfaces details information

#debug ip ospf events Displays all the ospf event messages on the router

# debug ip ospf adj Display information about ospf adjacencies and


authentication , including DR and BDR elections , sent
and receive hello packets , neighbor state transition and
database description information

#clear ip ospf process To reload the ospf process

ABR Router Summarization Description


#router ospf 1 Enabling OSPF protocol

#area 20 range 100.0.0.0 255.255.252.0 Will summarize this network

#show ip route ospf To check the summarization

ABR _ Area Border Gateway is a router that connects one or more areas to the OSPF backbone .

between areas we need at least one ABR router . we can have one ABR for 3 different area but is not

recommended.

5|Page
MAHTABPUZESHI

ASBR Router Summarization Description


#router ospf 1 Enabling OSPF protocol

#summary-address 100.0.0.0 255.255.252.0 Will summarize this network

#show ip route ospf To check the summarization

ASBR _ Autonomous system border router is a router that is connected to one or more logical

entities (AS), usually through an exterior routing protocol such as BGP. Only ABR & ASBR can

summarization networks .

Redistribution Description
#router ospf 1 Enabling OSPF protocol

#redistribute rip subnets Merging different routing protocol table _

classful subnets

#show ip route ospf To check the routing table

6|Page
MAHTABPUZESHI

OSPF Filtering Type 3 Description


#interface loopback 0 Loopback selection

#ip ospf network point-to-point To advertise loopbacks with their real Mask

#ip prefix-list 100_0 deny 100.0.0.0 /23 ge 24 Will deny every mask >= 24

#ip prefix-list 100_0 permit 0.0.0.0/0 le 32 Will Permit the rest

#router ospf 1 To enable ospf protocol

#area 20 filter-list prefix 100_0 out To filter on outbound packets

#show ip prefix-list Display information about a prefix-list

There will be Conflict if you use both Summarization & Filtering together . so , you wont have

details route anymore .

7|Page

You might also like