VLAN routing interface example configuration

VLANs divide broadcast domains in a LAN environment. When hosts in one VLAN must communicate with hosts in another VLAN, the traffic must be routed between them. This is known as inter-VLAN routing. On the switch, it is accomplished by creating Layer 3 interfaces (switch virtual interfaces [SVI]).

When a port is enabled for bridging (the default) rather than routing, all normal bridge processing is performed for an inbound packet, which is then associated with a VLAN. Its MAC destination address and VLAN ID are used to search the MAC address table. If routing is enabled for the VLAN, and the MAC destination address of an inbound unicast packet is that of the internal bridge-router interface, the packet is routed. An inbound multicast packet is forwarded to all ports in the VLAN, plus the internal bridge-router interface, if it was received on a routing VLAN.

Because a port can be configured to belong to more than one VLAN, VLAN routing might be enabled for all of the VLANs on the port, or for a subset. VLAN routing can be used to allow more than one physical port to reside on the same subnet. It might also be used when a VLAN spans multiple physical networks, or when additional segmentation or security is required. A port can be either a VLAN port or a router port, but not both. However, a VLAN port can be part of a VLAN that itself functions as a router port.

In this example, you do the following:
  1. Enable the IPv4 routing mode.
  2. Use the VLAN Static Routing Wizard to create a routing VLAN with VLAN ID 50, configure the IP address as 192.168.200.20 and the subnet mask as 255.255.255.0 for the routing VLAN interface, and add ports 7 and 8 xg7 and xg8 as untagged members of the routing VLAN.

For more information, see the following sections: