Configure Inter-VLAN Routing as SVI on Cisco Layer 3 or Multilayer Switch
In this tutorial, we will walk through the steps to configure inter-VLAN routing using Switch Virtual Interfaces (SVI) on a Cisco Layer 3 or Multilayer Switch. Inter-VLAN routing allows communication between devices in different VLANs by routing the traffic through a Layer 3 device.
Topology Overview
The network topology we will use includes:
- A Layer 3 switch (CS01) handling routing between VLANs.
- A Layer 2 switch (S1) connecting PCs in different VLANs.
- PCs in VLAN 10 (IT) with IP addresses in the range 192.168.10.0/24.
- PCs in VLAN 20 (HR) with IP addresses in the range 192.168.20.0/24.
Type of Inter-VLAN Routing
Configuration Steps
1. Enable Routing on Layer 3 Switch (CS01)
Switch>enable
Switch#configure terminal
Switch(config)#hostname CS01
CS01(config)#ip routing
2. Configure VLANs on CS01
CS01(config)#vlan 10
CS01(config-vlan)#name IT
CS01(config-vlan)#exit
CS01(config)#vlan 20
CS01(config-vlan)#name HR
CS01(config-vlan)#exit
3. Configure SVIs for VLANs on CS01
CS01(config)#interface vlan 10
CS01(config-if)#ip address 192.168.10.1 255.255.255.0
CS01(config-if)#exit
CS01(config)#interface vlan 20
CS01(config-if)#ip address 192.168.20.1 255.255.255.0
CS01(config-if)#exit
4. Configure Trunk Port on CS01
CS01(config)#interface gigabitEthernet 1/0/1
CS01(config-if)#switchport mode trunk
CS01(config-if)#exit
5. Configure VLANs on Layer 2 Switch (S1)
Switch>enable
Switch#configure terminal
Switch(config)#hostname S1
S1(config)#vlan 10
S1(config-vlan)#name IT
S1(config-vlan)#exit
S1(config)#vlan 20
S1(config-vlan)#name HR
S1(config-vlan)#exit
6. Assign Ports to VLANs on S1
S1(config)#interface range fastEthernet 0/10-11
S1(config-if-range)#switchport mode access
S1(config-if-range)#switchport access vlan 10
S1(config-if-range)#exit
S1(config)#interface range fastEthernet 0/20-21
S1(config-if-range)#switchport mode access
S1(config-if-range)#switchport access vlan 20
S1(config-if-range)#exit
7. Configure Trunk Port on S1
S1(config)#interface gigabitEthernet 0/1
S1(config-if)#switchport mode trunk
S1(config-if)#exit
Verification
After completing the configuration, verify the setup by checking connectivity between PCs in different VLANs. You should be able to ping from a PC in VLAN 10 to a PC in VLAN 20, demonstrating successful inter-VLAN routing.
Conclusion
By following these steps, you can configure inter-VLAN routing using SVIs on a Cisco Layer 3 or Multilayer Switch, enabling communication between different VLANs in your network. This setup is crucial for segmenting network traffic while maintaining connectivity and control across various departments or groups within an organization.