Packet tracer switch layer 3 ได ม ย

With a Layer 3 switch, you gain the ability to create Switch virtual interfaces (SVIs) for each VLAN and assign IP addresses to these interfaces. These IP addresses assigned to the SVIs serve as the default gateways for all the host devices residing within those VLANs.

In this post, I will show you how to configure layer 3 switch in the packet tracer. By the end of this post, you will have the knowledge and skills to:

  1. Create SVIs
  2. Assign IP addresses to the SVIs.
  3. Create Access ports
  4. Configure trunk links.
  5. Implement inter-VLAN routing With Multilayer switch.

Here is a vidoe tutorial showing How to Configure Layer 3 Switch in Packet Tracer;

Network Topology

The network topology shown below comprises of a layer 3 switch and 3 layer 2 switches attached to it. Each of the layer 3 switch is further connected to PCs.

Packet tracer switch layer 3 ได ม ย

Configuration Objectives

  1. Creating of SVIs on the Layer 3 Switch
  2. Creating of Trunk link
  3. Creating of Access port on Layer 2 switches
  4. Testing

Configuration

Below are the configurations needed for each of the network components and a brief explanation of what each configuration does.

Multilayer Switch Configuration

Creating VLANs

Enter the following command to create the two vlans;

SWI(config)
# vlan 20  
SWI(config)
# exit  
SWI(config)
# vlan 30

Confirms the vlans…

SWI(config)
# do show vlan brief

Packet tracer switch layer 3 ได ม ย

Creating the trunk port

Enter the following commands to create trunk port on the layer 3 switch;

SWI(config)
# int fa0/1  
SWI(config-if)
# switchport trunk encapsulation dot1q  
SWI(config-if)
# switchport mode trunk  
SWI(config-if)
# int fa0/2  
SWI(config-if)
# switchport trunk encapsulation dot1q  
SWI(config-if)
# switchport mode trunk  
SWI(config)
# int fa0/3  
SWI(config-if)
# switchport trunk encapsulation dot1q  
SWI(config-if)
# switchport mode trunk

Creating SVIs

Enter the following commands to create SVIs and assign IP addresses to them;

SWI(config)
# int vlan 20  
SWI(config-if)
# ip address 192.168.2.1 255.255.255.0  
SWI(config-if)
# no shut  
SWI(config-if)
# int vlan 30  
SWI(config-if)
# ip address 192.168.1.1  255.255.255.0  
SWI(config-if)
# no shut

Enable IP Routing

Enter the following commands to enable Ip routing on the layer 3 Switch;

SWI(config)
# ip routing  
SWI(config)
# exit

Confirm IPs addresses on SVIs;

Enter the following command to confirm the ip address assigned to the vlans;

SWI
# show ip interface brief

Packet tracer switch layer 3 ได ม ย

Switch1 Configuration

Creating Trunk port

Enter the following commands to create the trunk port on the first layer 2 switch;

Note: This configuration completes the creation of Trunk link between Switch1 and the Layer 3 switch

Switch(config)
# int fa0/1  
Switch(config-if)
# switchport mode trunk  
Switch(config-if)
# exit

Creating VLANs

Enter the following commands to create VLAN 20 and VLAN 30 on swtich1;

Switch(config)
# vlan 20  
Switch(config-vlan)
# vlan 30

Creating Access ports

Enter the following commands to create access ports on switch1;

Switch(config-vlan)
# int fa0/2  
Switch(config-if)
# switchport mode access  
Switch(config-if)
# switchport access vlan 20  
Switch(config-if)
# do write

Switch2 Configuration

Creating Trunk port

Enter the following commands to create the trunk port on switch2;

Switch(config)
# int fa0/1  
Switch(config-if)
# switchport mode trunk

Creating VLANs

Enter the following commands to create VLAN 20 and VLAN 30 on swtich2;

SWI(config)
# do show vlan brief

0

Creating Access ports

Enter the following commands to create access ports on switch2;

SWI(config)
# do show vlan brief

1

Switch0 Configuration

Creating Trunk port

Enter the following commands to create the trunk port on switch0;

Switch(config)
# int fa0/1  
Switch(config-if)
# switchport mode trunk

Creating VLANs

Enter the following commands to create VLAN 20 and VLAN 30 on swtich0;

Switch(config)
# vlan 20  
Switch(config-vlan)
# vlan 30

Creating Access ports

Enter the following commands to create access ports on switch0;

SWI(config)
# do show vlan brief

4

Configure the host devices

Configure the host with Ip address as labeled in the network topology showed above.

Note PC1 and PC3 are in the 192.168.2.0/24 subnetwork while PC0 and PC2 are in the 192.168.21.0/24 subnetwork.

Testing

With the configuration we have completed on each of the network components, which comprises creating SVIs on the layer 3 switch, creating a trunk link between the layer 3 switch and each of the layer 2 switches, and creating an access port on the layer 2 switches, we have been able to achieve inter-VLAN routing in the network.

To test it, we have pinged from PC3 to PC2, and the result is as shown in the image below:

Packet tracer switch layer 3 ได ม ย

I am a passionate Networking Associate specializing in Telecommunications.

With a degree in Electronic engineering, I possess a strong understanding of electronic systems and the intricacies of telecommunications networks. I gained practical experience and valuable insights working for a prominent telecommunications company.

Additionally, I hold certifications in networking, which have solidified my expertise in network architecture, protocols, and optimization.