Default: 1.
Example
To configure a cost of 10 for advertising the IP address 172.16.112.2 configured for loopback interface 3 in an
OSPF area 192.5.0.0, enter the following commands:
switch(config)# interface loopback 3
switch(lo-3)# ip ospf 172.16.112.2 area 192.5.0.0
switch(lo-3)# ip ospf 172.16.112.2 cost 10
OSPF redistribution of loopback addresses
When you assign a loopback address to an OSPF area, the route redistribution of the loopback address is limited
to the specified area.
When route redistribution is enabled:
• The switch advertises a loopback IP address that is not assigned to an OSPF area as an OSPF
external
route to its OSPF neighbors, and handles it as a connected route.
• The switch advertises a loopback address that is assigned to an OSPF area as an OSPF
internal
route.
To enable redistribution of loopback IP addresses in OSPF, enter the
redistribution connected
command
Example
Assigning loopback IP addresses to OSPF areas
The loopback IP address 13.3.4.5 of loopback 2 is advertised only in OSPF area 0.0.0.111. The IP addresses
14.2.3.4 and 15.2.3.4 of loopback 1 are advertised in all OSPF areas. The lines in bold below show that the IP
address of loopback interface 2 is assigned to OSPF area 111.
switch(config)# interface loopback 1
switch(lo-1)# ip address 14.2.3.4
switch(lo-1)# ip address 15.2.3.4
switch(lo-1)# exit
switch(config)# interface loopback 2
switch(lo-2)# ip address 13.3.4.5
switch(lo-2)# ip ospf 15.2.3.4 area 0.0.0.111
switch(lo-2)# exit
Verifying OSPF redistribution of loopback interfaces
To verify the OSPF redistribution of loopback interfaces, enter the
show ip route
command from any context
level to display IP route table entries.
In this example, a loopback address assigned to an area is displayed as an
ospf intra-area
(internal) route
to its neighbor; a loopback address not assigned to a specific area is displayed as an
ospf external
route:
switch(config)# show ip route
IP Route Entries
204
Aruba 3810 / 5400R Multicast and Routing Guide for ArubaOS-
Switch 16.08