DES-7200 Configuration Guide Chapter 4 OSPF
Configuration
4-62
SwitchA(config-Loopback 0)#ip address 1.1.1.1 255.255.255.0
Configure Switch B
! Create OSPF process and specify the IP address range associated with this
routing process and the OPPF area to which these IP addresses belong.
SwitchB(config)#router ospf 1
SwitchB(config-router)#network 192.168.1.0 0.0.0.255 area 0
SwitchB(config-router)#network 192.168.2.0 0.0.0.255 area 1
SwitchB(config-router)#exit
! Configure loopback IP of 2.2.2.2 as the device ID of Switch B
SwitchB(config)#interface loopback 0
SwitchB (config-Loopback 0)#ip address 2.2.2.2 255.255.255.0
Configure Switch C
! Create OSPF process and specify the IP address range associated with this
routing process and the OPPF area to which these IP addresses belong.
SwitchC(config)#router ospf 1
SwitchC(config-router)#network 192.168.2.0 0.0.0.255 area 1
SwitchC(config-router)#network 192.168.3.0 0.0.0.255 area 2
SwitchC(config-router)#exit
! Configure loopback IP of 3.3.3.3 as the device ID of Switch C
SwitchC(config)#interface loopback 0
SwitchC(config-Loopback 0)#ip address 3.3.3.3 255.255.255.0
Configure Switch D
! Create OSPF process and specify the IP address range associated with this
routing process and the OPPF area to which these IP addresses belong.
SwitchD(config)#router ospf 1
SwitchD(config-router)#network 192.168.3.0 0.0.0.255 area 2
SwitchD(config-router)#exit
! Configure loopback IP of 4.4.4.4 as the device ID of Switch D
SwitchD(config)#interface loopback 0
SwitchD(config-Loopback 0)#ip address 4.4.4.4 255.255.255.0
Display OSPF routing table of Switch A
SwitchA#show ip route ospf
O IA 192.168.2.0/24 [110/2] via 192.168.1.2, 00:32:48, VLAN 10
Since Area 2 is not directly connected with Area 0, there is no routing information
about Area 2 in the routing table of Switch A.