4.3.8 Packet Tracer – Configure Layer 3 Switching and Inter-VLAN Routing (Instructions Answer)

4.3.8 Packet Tracer – Configure Layer 3 Switching and Inter-VLAN Routing (Instructor Version)

4.3.8 Packet Tracer – Configure Layer 3 Switching and Inter-VLAN Routing (Instructions Answer) 2

Addressing Table

Device Interface IP Address / Prefix
MLS VLAN 10 192.168.10.254 /24
2001:db8:acad:10::1/64
VLAN 20 192.168.20.254 /24
2001:db8:acad:20::1/64
VLAN 30 192.168.30.254/24
2001:db8:acad:30::1/64
VLAN 99 192.168.99.254/24
G0/2 209.165.200.225
2001:db8:acad:a::1/64
PC0 NIC 192.168.10.1
PC1 NIC 192.168.20.1
PC2 NIC 192.168.30.1
PC3 NIC 192.168.10.2/24
2001:db8:acad:10::2/64
PC4 NIC 192.168.20.2/24
2001:db8:acad:20::2/64
PC5 NIC 192.168.30.2
2001:db8:acad:10::2/64
S1 VLAN 99 192.168.99.1
S2 VLAN 99 192.168.99.2
S3 VLAN 99 192.168.99.3

Objectives

  • Part 1: Configure Layer 3 Switching
  • Part 2: Configure Inter-VLAN Routing
  • Part 3: Configure IPv6 Inter-VLAN Routing

Background / Scenario

A multilayer switch like the Cisco Catalyst 3650 is capable of both Layer 2 switching and Layer 3 routing. One of the advantages of using a multilayer switch is this dual functionality. A benefit for a small to medium-sized company would be the ability to purchase a single multilayer switch instead of separate switching and routing network devices. Capabilities of a multilayer switch include the ability to route from one VLAN to another using multiple switched virtual interfaces (SVIs), as well as the ability to convert a Layer 2 switchport to a Layer 3 interface.

Instructions

Part 1: Configure Layer 3 Switching

In Part 1, you will configure the GigabitEthernet 0/2 port on switch MLS as a routed port and verify that you can ping another Layer 3 address.

a. On MLS, configure G0/2 as a routed port and assign an IP address according to the Addressing Table.

MLS(config)# interface g0/2
MLS(config-if)# no switchport
MLS(config-if)# ip address 209.165.200.225 255.255.255.252

b. Verify connectivity to Cloud by pinging 209.165.200.226.

MLS# ping 209.165.200.226

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 209.165.200.226, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 0/0/0 ms

Part 2: Configure Inter-VLAN Routing

Step 1: Add VLANs.

Add VLANs to MLS according to the table below. Packet Tracer scoring is case-sensitive, so type the names exactly as shown.

VLAN Number VLAN Name
10 Staff
20 Student
30 Faculty
MLS(config)#vlan 10
MLS(config-vlan)#name Staff
MLS(config-vlan)#vlan 20
MLS(config-vlan)#name Student
MLS(config-vlan)#vlan 30
MLS(config-vlan)#name Faculty
Step 2: Configure SVI on MLS.

Configure and activate the SVI interfaces for VLANs 10, 20, 30, and 99 according to the Addressing Table. The configuration for VLAN 10 is shown below as an example.

MLS(config)# interface vlan 10
MLS(config-if)# ip address 192.168.10.254 255.255.255.0
MLS(config-if)#interface vlan 20
MLS(config-if)#ip address 192.168.20.254 255.255.255.0
MLS(config-if)#ipv6 address 2001:db8:acad:20::1/64
MLS(config-if)#interface vlan 30
MLS(config-if)#ip address 192.168.30.254 255.255.255.0
MLS(config-if)#ipv6 address 2001:db8:acad:30::1/64

MLS(config-if)#interface vlan 99
MLS(config-if)#ip address 192.168.99.254 255.255.255.0
MLS(config-if)#
Step 3: Configure Trunking on MLS.

Trunk configuration differs slightly on a Layer 3 switch. On the Layer 3 switch, the trunking interface needs to be encapsulated with the dot1q protocol, however it is not necessary to specify VLAN numbers as it is when working with a router and subinterfaces.

a. On MLS, configure interface g0/1.

b. Make the interface a static trunk port.

MLS(config-if)# switchport mode trunk

c. Specify the native VLAN as 99.

MLS(config-if)# switchport trunk native vlan 99

d. Encapsulate the link with the dot1q protocol.

MLS(config-if)# switchport trunk encapsulation dot1q

Note: Packet Tracer may not score the trunk encapsulation.

Step 4: Configure trunking on S1.

a. Configure interface g0/1 of S1 as a static trunk.

b. Configure the native VLAN on the trunk.

S1(config)#interface g0/1
S1(config-if)#switchport mode trunk
S1(config-if)#switchport trunk native vlan 99
Step 5: Enable routing.

a. Use the show ip route command. Are there any active routes? No

b. Enter the ip routing command to enable routing in global configuration mode.

MLS(config)# ip routing

c. Use the show ip route command to verify routing is enabled.

MLS# show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

C    192.168.10.0/24 is directly connected, Vlan10
C    192.168.20.0/24 is directly connected, Vlan20
C    192.168.30.0/24 is directly connected, Vlan30
C    192.168.99.0/24 is directly connected, Vlan99
     209.165.200.0/30 is subnetted, 1 subnets
C    209.165.200.224 is directly connected, GigabitEthernet0/2
Step 6: Verify end-to-end connectivity.

a. From PC0, ping PC3 or MLS to verify connectivity within VLAN 10.

b. From PC1, ping PC4 or MLS to verify connectivity within VLAN 20.

c. From PC2, ping PC5 or MLS to verify connectivity within VLAN 30.

d. From S1, ping S2, S3, or MLS to verify connectivity with VLAN 99.

e. To verify inter-VLAN routing, ping devices outside the sender’s VLAN.

f. From any device, ping this address inside Cloud, 209.165.200.226.

The Layer 3 switch is now routing between VLANs and providing routed connectivity to the cloud.

Part 3: Configure IPv6 Inter-VLAN Routing

Layer 3 switches also route between IPv6 networks.

Step 1: Enable IPv6 routing.

Enter the ipv6 unicast-routing command to enable IPv6 routing in global configuration mode.

MLS(config)# ipv6 unicast-routing
Step 2: Configure SVI for IPv6 on MLS.

Configure IPv6 addressing on SVI for VLANs 10, 20, and 30 according to the Addressing Table. The configuration for VLAN 10 is shown below.

MLS(config)# interface vlan 10
MLS(config-if)# ipv6 address 2001:db8:acad:10::1/64
Step 3: Configure G0/2 with IPv6 on MLS.

a. Configure IPv6 addressing on G0/2.

MLS(config)# interface G0/2
MLS(config-if)# ipv6 address 2001:db8:acad:a::1/64

b. Use the show ipv6 route command to verify IPv6 connected networks.

MLS# show ipv6 route
IPv6 Routing Table - 10 entries
Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP
       U - Per-user Static route, M - MIPv6
       I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary
       O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2
       ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2
       D - EIGRP, EX - EIGRP external
S   ::/0 [1/0]
     via 2001:DB8:ACAD:A::2, GigabitEthernet0/2
C   2001:DB8:ACAD:A::/64 [0/0]
     via ::, GigabitEthernet0/2
L   2001:DB8:ACAD:A::1/128 [0/0]
     via ::, GigabitEthernet0/2
C   2001:DB8:ACAD:10::/64 [0/0]
     via ::, Vlan10
L   2001:DB8:ACAD:10::1/128 [0/0]
     via ::, Vlan10
C   2001:DB8:ACAD:20::/64 [0/0]
     via ::, Vlan20
L   2001:DB8:ACAD:20::1/128 [0/0]
     via ::, Vlan20
C   2001:DB8:ACAD:30::/64 [0/0]
     via ::, Vlan30
L   2001:DB8:ACAD:30::1/128 [0/0]
     via ::, Vlan30
L   FF00::/8 [0/0]
     via ::, Null0
Step 4: Verify IPv6 connectivity.

Devices PC3, PC4, and PC5 have been configured with IPv6 addresses. Verify IPv6 inter-VLAN routing and connectivity to Cloud.

a. From PC3, ping MLS to verify connectivity within VLAN 10.

b. From PC4, ping MLS to verify connectivity within VLAN 20.

c. From PC5, ping MLS to verify connectivity within VLAN 30.

d. To verify inter-VLAN routing, ping between devices PC3, PC4, and PC5.

e. From PC3 ping the address inside Cloud, 2001:db8:acad:a::2.

Script Answers – Download PDF & PKA file:

enable
config t
ip routing
ipv6 unicast-routing
interface GigabitEthernet0/1
 switchport trunk native vlan 999
 switchport trunk encapsulation dot1q
 switchport mode trunk
interface GigabitEthernet0/2
 no switchport
 ip address 209.165.200.225 255.255.255.252
 ipv6 address 2001:DB8:ACAD:A::1/64vlan 10
 name Staff
vlan 20
 name Student
vlan 30
 name Faculty
interface Vlan10
 ip address 192.168.10.254 255.255.255.0
 ipv6 address 2001:DB8:ACAD:10::1/64
 no shutdown
interface Vlan20
 ip address 192.168.20.254 255.255.255.0 
 ipv6 address 2001:DB8:ACAD:20::1/64
 no shutdown
interface Vlan30
 ip address 192.168.30.254 255.255.255.0
 ipv6 address 2001:DB8:ACAD:30::1/64
 no shutdown
interface Vlan99
 ip address 192.168.99.254 255.255.255.0
 no shutdown
end

enable
conf t
int g0/1
switchport mode trunk
switchport trunk native vlan 99
end

Download Packet Tracer (.pka) file:

Subscribe
Notify of
guest

5 Comments
Inline Feedbacks
View all comments
Tyrone Walker
Tyrone Walker
1 year ago

hello, this is not a correct answer for g0/1 the answer is suppose to be VLAN 99 not VLAN 999

mrX
mrX
1 year ago

MLS>enable
MLS#config t
Enter configuration commands, one per line. End with CNTL/Z.
MLS(config)#int g0/2
MLS(config-if)#no switchport
MLS(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/2, changed state to up

MLS(config-if)#ip add 209.165.200.225 255.255.255.252
MLS(config-if)#exit
MLS(config)#vlan 10
MLS(config-vlan)#name Staff
MLS(config-vlan)#vlan 20
MLS(config-vlan)#name Student
MLS(config-vlan)#vlan 30
MLS(config-vlan)#name Faculty
MLS(config-vlan)#exit
MLS(config)# show vlan brief
       ^
% Invalid input detected at ‘^’ marker.

MLS(config)#do show vlan brief

VLAN Name               Status  Ports
—- ——————————– ——— ——————————-
1  default             active  Fa0/1, Fa0/2, Fa0/3, Fa0/4
                        Fa0/5, Fa0/6, Fa0/7, Fa0/8
                        Fa0/9, Fa0/10, Fa0/11, Fa0/12
                        Fa0/13, Fa0/14, Fa0/15, Fa0/16
                        Fa0/17, Fa0/18, Fa0/19, Fa0/20
                        Fa0/21, Fa0/22, Fa0/23, Fa0/24
                        Gig0/1
10  Staff              active   
20  Student             active   
30  Faculty             active   
99  Management            active   
999 VLAN0999             active   
1002 fddi-default           active   
1003 token-ring-default        active   
1004 fddinet-default         active   
1005 trnet-default          active   
MLS(config)#int vlan 10
MLS(config-if)#
%LINK-5-CHANGED: Interface Vlan10, changed state to up

MLS(config-if)#ip add 192.169.10.254 255.255.255.0
MLS(config-if)#exit
MLS(config)#int vlan 20
MLS(config-if)#
%LINK-5-CHANGED: Interface Vlan20, changed state to up

MLS(config-if)#ip add 192.168.20.254 255.255.255.0
MLS(config-if)#exit
MLS(config)#
MLS(config)#int vlan 30
MLS(config-if)#
%LINK-5-CHANGED: Interface Vlan30, changed state to up

MLS(config-if)#ip add 192.168.30.254 255.255.255.0
MLS(config-if)#exit
MLS(config)#int vlan 10
MLS(config-if)#ip add 192.168.10.254 255.255.255.0
MLS(config-if)#exit
MLS(config)#int vlan 99
MLS(config-if)#
%LINK-5-CHANGED: Interface Vlan99, changed state to up

MLS(config-if)#ip add 192.168.99.254 255.255.255.0
MLS(config-if)#exit
MLS(config)#int g0/1
MLS(config-if)#switchport mode trunk

MLS(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/1, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan10, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan20, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan30, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Vlan99, changed state to up

MLS(config-if)#switchport trunk native vlan 99
MLS(config-if)#switchport trunk encapsulation
% Incomplete command.
MLS(config-if)#
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on GigabitEthernet0/1 (99), with S1 GigabitEthernet0/1 (1).

MLS(config-if)#switchport trunk encap dot1q
MLS(config-if)#
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on GigabitEthernet0/1 (99), with S1 GigabitEthernet0/1 (1).

MLS(config-if)#
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on GigabitEthernet0/1 (99), with S1 GigabitEthernet0/1 (1).

MLS(config-if)#
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on GigabitEthernet0/1 (99), with S1 GigabitEthernet0/1 (1).

MLS(config-if)#%SPANTREE-2-RECV_PVID_ERR: Received BPDU with inconsistent peer vlan id 1 on GigabitEthernet0/1 VLAN99.

%SPANTREE-2-BLOCK_PVID_LOCAL: Blocking GigabitEthernet0/1 on VLAN0099. Inconsistent local vlan.

MLS(config-if)#
%CDP-4-NATIVE_VLAN_MISMATCH: Native VLAN mismatch discovered on GigabitEthernet0/1 (99), with S1 GigabitEthernet0/1 (1).

MLS(config-if)#%SPANTREE-2-UNBLOCK_CONSIST_PORT: Unblocking GigabitEthernet0/1 on VLAN0001. Port consistency restored.

%SPANTREE-2-UNBLOCK_CONSIST_PORT: Unblocking GigabitEthernet0/1 on VLAN0099. Port consistency restored.

MLS(config-if)#exit
MLS(config)#ipv6 unicast-routing
MLS(config)#int g0/2
MLS(config-if)#ipv6 add 2001:db8:acad:a::1/64
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#exit
MLS(config)#do show run
Building configuration…

Current configuration : 1814 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname MLS
!
!
!
!
!
!
ipv6 unicast-routing
!
!
!
!
!
!
!
!
!
!
!
!
!
!

MLS(config)#int vlan 10
MLS(config-if)#ipv6 address 2001:db8:acad:10::1/64
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#exit
MLS(config)#int vlan 20
MLS(config-if)#ipv6 add 2001:db8:acad:20::1/64
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#exit
MLS(config)#int vlan 30
MLS(config-if)#ipv6 add 2001:db8:acad:30::1/64
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#
MLS(config-if)#exit
MLS(config)#ip v6 unicst-routing
        ^
% Invalid input detected at ‘^’ marker.

MLS(config)#ipv6 unicast-routing
MLS(config)#ip routing
MLS(config)#exit
MLS#
%SYS-5-CONFIG_I: Configured from console by console

MLS#

quien sabe
quien sabe
1 year ago

=D
%MLS%

enable
config t
ip routing
ipv6 unicast-routing
interface GigabitEthernet0/1
 switchport mode trunk
 switchport trunk native vlan 99
 switchport trunk encapsulation dot1q
interface GigabitEthernet0/2
 no switchport
 ip address 209.165.200.225 255.255.255.252
 ipv6 address 2001:db8:acad:a::1/64
vlan 10
 name Staff
vlan 20
 name Student
vlan 30
 name Faculty
interface Vlan 10
 ip address 192.168.10.254 255.255.255.0
 ipv6 address 2001:DB8:ACAD:10::1/64
 no shutdown
interface Vlan20
 ip address 192.168.20.254 255.255.255.0 
 ipv6 address 2001:DB8:ACAD:20::1/64
 no shutdown
interface Vlan30
 ip address 192.168.30.254 255.255.255.0
 ipv6 address 2001:DB8:ACAD:30::1/64
 no shutdown
interface Vlan99
 ip address 192.168.99.254 255.255.255.0
 no shutdown
end

  %S1%

enable
conf t
int g0/1
switchport mode trunk
switchport trunk native vlan 99
end

uKNOWN
uKNOWN
2 years ago

He’s right ^

Unknown
Unknown
2 years ago

The switchport native vlan for interface g0/1 is 99 not 999. So while interfacing g0/1 the command should be

 switchport trunk native vlan 99
5
0
Would love your thoughts, please comment.x
()
x