Multicast and Routing Guide K/KA/KB.15.15

NOTE: If you add a new subnet IP address to a VLAN after assigning the VLAN
to an OSPF area, you must also assign the new subnet to an area:
If all subnets in the VLAN should be assigned to the same area, just execute
ip ospf area ospf-area-id .
But if different subnets belong in different areas, you must explicitly assign the
new subnet to the desired area.
Also, to assign a VLAN to an OSPF area, the VLAN must be configured with at
least one IP address. Otherwise, executing this command results in the following
CLI message:
OSPF can not be configured on this VLAN.
Example
To assign VLAN 8 on a routing switch to area 3 and include all IP addresses
configured in the VLAN, enter the following commands:
HP Switch(ospf)# vlan 8
HP Switch(vlan-8)# ip ospf area 3
Suppose that a system operator wants to assign the three subnets configured in
VLAN 10 as shown below:
10.10.10.1 to OSPF area 5
10.10.11.1 to OSPF area 5
10.10.12.1 to OSPF area 6
The operator could use the following commands to configure the above assignments:
HP Switch(ospf)# vlan 10
HP Switch(vlan-10)# ip ospf 10.10.10.1 area 5
HP Switch(vlan-10)# ip ospf 10.10.11.1 area 5
HP Switch(vlan-10)# ip ospf 10.10.12.1 area 6
Assigning loopback addresses to an area
Optional: After you define the OSPF areas to which the switch belongs, you can assign a
user-defined loopback address to an OSPF area. A loopback interface is a virtual interface
configured with an IP address and is always reachable as long as at least one of the IP interfaces
on the switch is operational. Because the loopback interface is always up, you ensure that the
switch's router ID remains constant and that an OSPF network is protected from changes caused
by downed interfaces.
For more information, see the Management and Configuration Guide for your switch.
Syntax:
interface loopback 0-7 ip ospf lo-ipaddress area ospf-area-id
Executed in a specific loopback context to assign a loopback interface to the
specified OSPF area. Requires that the specified loopback interface is already
configured with an IP address on the switch.
interface loopback 0-7 Defines the loopback context for executing the
area assignment.
ip ospf lo-ipaddress Specifies the loopback interface by its IP
address to assign to a configured OSPF area.
area ospf-area-id Identifies the OSPF area to which the loopback
interface is assigned.
146 Open Shortest Path First Protocol (OSPF)