1 00:00:14,850 --> 00:00:21,570 Okay so let's start with the router, at the moment on the router. 2 00:00:21,860 --> 00:00:25,070 No IP addresses are configured. 3 00:00:25,070 --> 00:00:31,550 So the first thing we need to do is go on to the gigabit 000 interface and no shut it 4 00:00:34,940 --> 00:00:40,100 and then we need to create sub-interfaces. 5 00:00:40,100 --> 00:00:47,530 So notice I'm gonna choose .1 as the sub-interface for VLAN 1. 6 00:00:47,610 --> 00:00:56,830 I'm gonna specify an encapsulation of .1Q using VLAN 1 as the native VLAN the management VLAN 7 00:00:57,240 --> 00:01:02,480 is typically your untagged VLAN which by default is VLAN 1. 8 00:01:03,260 --> 00:01:12,090 I can now configure the IP address of the router the last IP address in subnet 10.1.1.0/24 is 9 00:01:12,090 --> 00:01:24,210 10.1.1.1.254. So do show run shows us the configuration of the first sub interface. 10 00:01:24,210 --> 00:01:29,100 We now need to configure the second sub-interface which is VLAN 10. 11 00:01:29,130 --> 00:01:35,400 You don't have to use the same numbers as the VLAN number that just makes it easier. 12 00:01:35,670 --> 00:01:38,770 So I'm gonna specify VLAN 10. 13 00:01:38,790 --> 00:01:45,580 This is not the native VLAN, IP address is 10.1.10.254. 14 00:01:47,790 --> 00:01:49,280 So again show run 15 00:01:52,250 --> 00:02:00,310 there is the configuration of VLAN 10 and then I need to create a third sub-interface for VLAN 16 00:02:00,310 --> 00:02:10,360 20 encapsulation is gonna be .1Q VLAN 20 IP address is gonna be 10.1.20.254 17 00:02:10,780 --> 00:02:12,850 /24. 18 00:02:12,850 --> 00:02:23,560 So again there's the configuration of the physical interface VLAN 1 sub-interface, VLAN 10 19 00:02:23,560 --> 00:02:27,680 sub-interface, VLAN 20 sub-interface. 20 00:02:27,900 --> 00:02:36,840 The next thing we need to do is configure the switch so on the switch show IP interface brief no IP 21 00:02:36,840 --> 00:02:45,890 addresses are configured VLAN 1 is administratively down at the moment. So CONFT interface of VLAN 22 00:02:45,940 --> 00:02:59,020 1 no shut IP address 10.1.1.253/24 we've been told to only configure an IP address 23 00:02:59,050 --> 00:03:09,070 in VLAN 1. So let's confirm that the switch can ping the router it can but that's not entirely correct 24 00:03:09,130 --> 00:03:20,160 yet we still need to configure this interface as a trunk port VLAN 1 will work because it's the 25 00:03:20,160 --> 00:03:29,520 native VLAN but other VLANs will not work. So switch port mode trunk we need to specify an encapsulation. 26 00:03:30,200 --> 00:03:35,640 So switch port trunk encapsulation .1Q 27 00:03:38,470 --> 00:03:41,560 and now we can make the port a trunk port. 28 00:03:41,860 --> 00:03:44,200 So those two commands are required. 29 00:03:44,200 --> 00:03:47,540 Interface went down, it's now come up again. 30 00:03:47,830 --> 00:03:50,500 So show run. 31 00:03:50,630 --> 00:03:52,160 They are the two commands in gigabit 32 00:03:52,170 --> 00:03:55,510 101. 33 00:03:55,640 --> 00:04:01,810 Can we still ping the router? At the moment it's not working but now it is. 34 00:04:01,810 --> 00:04:05,710 It just took it a while to notice the pings have now succeeded. 35 00:04:05,740 --> 00:04:08,820 Packet tracers showing green on the link. 36 00:04:09,520 --> 00:04:11,710 So that looks good. 37 00:04:11,710 --> 00:04:17,519 We now need to configure VLAN 10 and VLAN 20 38 00:04:17,860 --> 00:04:22,390 and we need to put our PCs into those VLANs. 39 00:04:22,780 --> 00:04:31,800 So our two PCs are connected to ports 102 and 103. 40 00:04:31,930 --> 00:04:33,560 So interface gigabit. 41 00:04:33,730 --> 00:04:41,900 102 switch port mode access, switch port access VLAN 10. 42 00:04:41,920 --> 00:04:44,160 In this case interface gigabit 43 00:04:44,170 --> 00:04:55,060 103 switch port mode access because it's a P.C. switch port access VLAN 20. So show run, 44 00:04:55,060 --> 00:05:09,000 what have we configured? Gigabit 101 is a trunk port gigabit 102 and 103 are access ports 102 45 00:05:09,000 --> 00:05:19,200 is in VLAN 10, 103 is in VLAN 20. So we can use commands such as show interface gigabit 101 switch 46 00:05:19,200 --> 00:05:23,930 port to verify the configuration of an interface. 47 00:05:24,270 --> 00:05:27,690 So this command shows us that gigabit 48 00:05:27,690 --> 00:05:34,330 101 is configured as a trunk port and is operating as a trunk port. 49 00:05:34,410 --> 00:05:44,680 The encapsulation used is .1Q access VLAN is VLAN 1 if we look at Interface gigabit 50 00:05:44,680 --> 00:05:59,660 102 this port is an access port in VLAN 10 look at 103 this port is an access port in VLAN 20 51 00:06:00,510 --> 00:06:01,870 so that looks good. 52 00:06:03,790 --> 00:06:09,450 We've configured the VLANs on the switch we've configured the link between the router and the switch. 53 00:06:09,460 --> 00:06:12,790 Now we need to confirm that the PCs can ping each other. 54 00:06:12,950 --> 00:06:20,800 So on PC 1, we've been told to configure the PC with a static IP address the default gateway will be 55 00:06:20,800 --> 00:06:31,690 the router on the PC. So I'll set both the default gateway and DNS to the router the IP address will 56 00:06:31,690 --> 00:06:41,350 be 10.1.10.1 subnet mask is gonna be a /24 subnet mask. So on the command 57 00:06:41,380 --> 00:06:49,990 prompt IP config we can see the configuration of the PC that's correct 58 00:06:49,990 --> 00:06:56,380 per our instructions default gateway is wrong I should make that 10 59 00:06:56,380 --> 00:06:59,380 always good to verify. 60 00:06:59,770 --> 00:07:01,160 So do that again. 61 00:07:01,240 --> 00:07:07,380 That looks better can we ping the default gateway? 62 00:07:07,510 --> 00:07:08,290 Yes, we can. 63 00:07:08,350 --> 00:07:17,680 So that's good do something similar on PC 2 default gateway will be 10.1.20.2 64 00:07:17,680 --> 00:07:26,860 54 DNS server will be 10.1.20.254, IP address of the PC will be 10. 65 00:07:26,860 --> 00:07:35,820 1.20.2 subnet mask will be /24 subnet mask open up a command prompt IP config 66 00:07:37,270 --> 00:07:39,130 that looks good. Can we ping 67 00:07:41,770 --> 00:07:42,620 the router? 68 00:07:42,760 --> 00:07:44,260 Yes, we can. 69 00:07:44,260 --> 00:07:45,280 Can we ping 70 00:07:45,460 --> 00:07:49,090 PC 1? So ping 10.1.10.1 71 00:07:49,240 --> 00:08:01,220 Yes, we can. So PC 2 is able to ping PC 1 and can PC 1 ping PC 2? Yes, it can. 72 00:08:01,220 --> 00:08:09,350 So we've successfully configured this network with VLANs and inter VLAN routing using a router on 73 00:08:09,350 --> 00:08:11,190 a stick. 74 00:08:11,190 --> 00:08:15,110 So now let's do the extra work for credits. 75 00:08:15,210 --> 00:08:20,180 How do we get everyone to talk to everyone? So on the switch 76 00:08:20,210 --> 00:08:24,500 we need to configure an IP default gateway 77 00:08:28,250 --> 00:08:37,289 pointing to the router in the same subnet at the switch. So ping 10.1.1.254, 78 00:08:37,460 --> 00:08:38,090 that works. 79 00:08:38,090 --> 00:08:49,330 Can the switch ping the first PC? At the moment it looks like it can't. Can it ping the second PC? 80 00:08:49,420 --> 00:08:51,990 At the moment it looks like it can't. 81 00:08:52,120 --> 00:08:58,780 When you use IP default gateway you need to ensure that routing is disabled. 82 00:08:58,810 --> 00:09:01,400 In this example routing is enabled. 83 00:09:01,420 --> 00:09:08,560 So we gonna say no IP routing because this is a layer 2 switch and not a layer 3 switch and that 84 00:09:08,650 --> 00:09:14,140 should allow us to ping the pieces which it does. 85 00:09:14,260 --> 00:09:15,880 So this is the lesson. 86 00:09:16,120 --> 00:09:24,790 If you have IP routing enabled you don't use the default-gateway command. 87 00:09:24,790 --> 00:09:33,030 So as soon as I enable IP routing on the switch the IP default gateway command is ignored by the switch 88 00:09:33,420 --> 00:09:36,820 and the switch can't ping the pieces. 89 00:09:36,930 --> 00:09:42,870 Now typically on switches, the default behavior is to have IP routing disabled. 90 00:09:42,870 --> 00:09:47,160 So this is the default behavior. In this lab 91 00:09:47,160 --> 00:09:49,690 however it was turned on. 92 00:09:49,950 --> 00:09:59,060 So we need to verify that it's off so that we can ping the PCs using the IP default-gateway command. 93 00:09:59,070 --> 00:10:04,430 So can PC 1 ping the switch, ping 10.1.1.253? 94 00:10:05,220 --> 00:10:10,470 Yes, it can. Can PC 2 ping the switch? 95 00:10:14,160 --> 00:10:15,370 Yes, it can. 96 00:10:15,420 --> 00:10:20,670 So we successfully configured this network per our instructions. 97 00:10:20,670 --> 00:10:24,420 Don't forget to save your configurations on your devices. 98 00:10:26,590 --> 00:10:31,990 In the exam, you may have to use the command copy running-config startup-config. 99 00:10:31,990 --> 00:10:39,070 Here I'm simply using the old command W R but I would suggest in the exam that when you finish save 100 00:10:39,070 --> 00:10:44,090 your configurations. I hope you found this video useful.