In the previous video, we already learn about trunk. After configuring trunk, 2
now same vlan between room can communicate each others. Vlan 10 in the room 1 can communicate 3
with vlan 10 in the room 2. And vlan 20 in room 1 also can communicate with vlan 20 in room 2. 4
Next in this video, we are going to learn about allowed trunk. Let’s just start! 5
Let’s open switch 1, enable, and show interface trunk. 6
Here we have interface trunk, which is fa0/5. Here we can see allowed on trunk. 7
This is means which vlan that allowed to pass the interface. 8
By default, all vlans is allowed to pass the interface trunk, 9
here we can see that the allowed on trunk is vlan 1 until 1005. In the real device, 10
the allowed on trunk will be 1 until 4095. Because the number of vlan is between 1 until 4095. 11
Here we can configure custom allowed trunk. 12
So we can configure which vlan can pass the interface trunk. 13
Let’s say here we only have vlan 10 and vlan 20. 14
For security reason we want to configure so only vlan 10 and vlan 20 can pass the interface trunk. 15
Let’s configure the allowed trunk. Conf t, and then go to interface fa0/5. 16
To configure allowed trunk, the command is switchport trunk allowed vlan 10, 20. 17
Now let’s see the interface trunk. 18
Okay here we can see that now allowed on trunk is only vlan 10 and 20. 19
Let’s also configure in switch 2. Conf t, interface fa0/5, 20
and then switchport trunk allowed vlan 10,20. 21
Let’s see the trunk, 22
do show interface trunk. Okay here we can see that now the allowed on trunk is only vlan 10 and 20. 23
Now let’s try to communicate between PC in the vlan 10. 24
Okay this is success. Now let’s try between PC in the vlan 20. Okay this is also success. 25
So now all PC in the same vlan still can communicate each others. 26
This is because vlan 10 and vlan 20 is allowed to pass the interface trunk. 27
Now let’s try to add a PC. let’s say we will configure this PC to vlan 30. 28
Let’s change the name of the PC. let’s say PC 9. 29
And here PC 10, let’s connecting this to switch 2. This PC will also in the vlan 30. 30
Now let’s configure the switch, here fa0/6 will be in the vlan 30. Let’s create the vlan first. 31
Let’s say the name is engineering. And then assign the interface fa0/6 to the vlan 30. 32
Interface fa0/6, switchport mode access, switchport access vlan 30. 33
Let’s verify it, do show vlan brief. Okay here we can see that fa0/6 is in the vlan 30. 34
Next let’s configure on switch 2. Here fa0/6 will also in the vlan 30. Let’s create the vlan first. 35
And then assign interface fa0/6 to the vlan 30. Interface fa0/6, switchport mode access 36
and then switchport access vlan 30. 37
Let’s verify it, do show vlan brief. 38
Oh I'm sorry, here I do a mistake 39
This is should not fa0/3 but fa0/6. 40
So let’s bring fa0/3 back to vlan 20. Interface fa0/3, switchport access vlan 20. 41
Now let’s configure fa0/6, interface fa0/6, switchport mode access, and then switchport access vlan 30. 42
Let’s verify it again, do show vlan brief. 43
Okay here we can see that fa0/3 and fa0/4 is in the vlan 20, and then fa0/6 is in the vlan 30. This is correct. 44
Now let’s try to ping between PC in the vlan 30. 45
Okay here we get an error PC 10 has no functional port. This is because we don’t configure the 46
ip address yet. Let’s configure it first. For PC 9, let’s say the ip address is 192.168.1.9. 47
for PC 10, the ip address is 192.168.1.10. Okay now let’s ping again from PC 9 to PC 10. 48
Okay here we can see that the result is failed. Let’s try again, okay still failed. 49
Why? This is because the allowed on trunk is only vlan 10 and 20. 50
Let’s see it again, do show interface trunk. 51
Here we can see that the allowed on trunk is only vlan 10 and 20. 52
Vlan 30 is not allowed to pass the interface trunk 53
Now let’s configure so vlan 30 will allowed to pass the interface trunk. 54
Go to interface fa0/5, and then switchport trunk allowed vlan, 55
and here earlier we directly put the number of vlan, which is 10 and 20 like that, 56
But if now we directly put the number of vlan like this, so the allowed on trunk 57
will be only vlan 30. Vlan 10 and vlan 20 will be removed from allowed on trunk. 58
Let’s just try it. Now let’s verify it. 59
Okay here we can see that now vlan 10 and vlan 20 is removed from allowed on trunk. 60
So we need to be careful here. 61
Okay now let’s bring the vlan 10 and vlan 20 back to allowed on trunk. 62
Let’s verify it again, okay now here we can see that the allowed on trunk is vlan 10 and 20. 63
The question is, 64
how we can add vlan 30 to the allowed on trunk without removing the vlan 10 and 20? 65
Let’s just try it. Actually the command is similar, so switchport port 66
trunk allowed vlan, and here we need to use one more command, which is add. 67
So switchport trunk allowed vlan add and then the number of vlan, which is 30. 68
Let’s verify it. Do show interface trunk. Okay here we can see that now, 69
the allowed on trunk is vlan 10 20 and 30. Let’s also configure on switch 2. 70
Interface fa0/5. Switchport trunk allowed vlan add 30. Let’s verify it, 71
do show interface trunk. Okay here we can see that the allowed on trunk is vlan 10, 20 and 30. 72
Now let’s try ping between PC in the vlan 30. Okay now the result is success. 73
I think enough for this video, I hope you understand 74
about allowed on trunk. 75
Thankyou for watching and see you on the next video!