Practical 10
OSPF Configuration
OSPF neighborhood discovery
Routers running OSPF need to establish a neighbor relationship before
exchanging routing updates. OSPF neighbors are dynamically discovered by
sending Hello packets out each OSPF-enabled interface on a router. Hello packets
are sent to the multicast address of 224.0.0.5.
OSPF areas
An area is simply a logical grouping of adjacent networks and routers. All routers
in the same area have the same topology table and don’t know about routers in
other areas. The main benefits of using areas in an OSPF network are:
Routing tables on the routers are reduced.
Routing updates are reduced.
Each area in an OSPF network must be connected to the backbone area ( also
known as area 0 ). All routers inside an area must have the same area ID .
A router that has interfaces in more than one area (for example area 0 and area 1)
is known as an Area Border Router (ABR). A router that connects an OSPF
network to other routing networks (for example, to an EIGRP network) is called
an Autonomous System Border Router (ASBR).
OSPF with single area
Router 0
Router(config)#router ospf 1
Router(config-router)#network 192.168.1.0 0.0.0.255 area 0
Router(config-router)#network 192.168.3.0 0.0.0.255 area 0
Router 1
Router(config)#router ospf 2
Router(config-router)#network 192.168.2.0 0.0.0.255 area 0
Router(config-router)#network 192.168.3.0 0.0.0.255 area 0
OSPF with multi area
Router 0
Router(config)#router ospf 1
Router(config-router)#network 192.168.1.0 0.0.0.255 area 0
Router(config-router)#network 192.168.4.0 0.0.0.255 area 0
Router 1
Router(config)#router ospf 2
Router(config-router)#network 192.168.2.0 0.0.0.255 area 2
Router(config-router)#network 192.168.4.0 0.0.0.255 area 0
Router(config-router)#network 192.168.5.0 0.0.0.255 area 1
Router 2
Router(config)#router ospf 3
Router(config-router)#network 192.168.3.0 0.0.0.255 area 1
Router(config-router)#network 192.168.5.0 0.0.0.255 area 1
Exercise
OSPF with multi area