Content

| 4.2 |  | Configuring Inter-VLAN Routing |
| 4.2.2 |  | Configuring inter-VLAN routing via the switch virtual interface |

By far the most common method of achieving Inter-VLAN routing is to configure the switch virtual interface. Using this technique, the router has a virtual interface in every VLAN created on the switch. Rather than configuring a physical interface for each VLAN, the router uses a virtual or VLAN interface. For example, the following commands will allow the router to route traffic to and from VLAN 55.

> Switch(config)#interface vlan 55
> Switch(config-if)#ip address 10.0.1.1 255.255.255.0

These commands have the same effect as if a physical router interface was connected to a switch port in the appropriate VLAN.

The no shutdown interface command is required when configuring an interface for VLAN1.

> Switch(config)#interface vlan 1
> Switch(config-if)#ip address 10.0.0.1 255.255.255.0
> Switch(config-if)#no shutdown