A Trunk link is a point-to-point link between
two network devices. Trunk links carry more than one VLAN. With VLAN trunking,
we can extend our configured VLAN across the entire network. Remember,
sending information from an access link on one VLAN to another VLAN is not
possible without the additional device a router, or an external layer 2 bridge
connected between the VLAN.
A Trunk link can transport multiple VLAN traffic through a
single switch port. A trunk link is not assigned to a specific VLAN.
Types of links/ports.
Access links
- Connecting to end devices (hosts or router)
- Part of one VLAN
![]() |
ACCESS LINK |
Trunk links
- Do not belong to any VLAN
- It Carry multiple VLAN traffic
- It’s a physical Link between two switches
![]() |
TRUNK LINK |
Frame tagging
In order to make sure that the same VLAN users on different
switches communicate with each other there is a method of tagging happens on
trunk links. A tag is added before a frame is sent and removed once it is
received on the trunk link. Frame tagging happens only on the trunk links.
VLAN Frame Identification
A Trunk link can transport multiple VLAN traffic; a switch
must identify frames with their respective VLANs as they are sent and received
over a trunk link.
VLAN identification can be performed using two methods, each using a different frame identification mechanism:
- Inter-switch link (ISL) protocol
- IEEE 802.1Q (Dot1Q) protocol
Inter-switch link (ISL) is a Cisco-proprietary method for
preserving the source VLAN identification of frame passing over the trunk link. ISL
works with Ethernet, Token ring, and FDDI. ISL adds a 26-byte header and a byte
trailer to the frame you can say its adds 30 bytes of tag. The ISL method of
VLAN identification or trunking encapsulation no longer is supported across all
Cisco catalyst switch platforms.
The IEEE 802.1Q protocol is also used to carry VLAN traffic,
dot1q is an open standard trunking protocol, it works only on Ethernet, dot1q
introduces us to the concept of Native VLAN on a trunk. The frame belongs to native
VLAN is not encapsulation and with no tag. Dot1q is only adding 4 bytes tag
will be added to the original frame just after the source address field.
Let's see the configuration:
Topology:-
GOAL:
- configure VLAN 110, and VLAN 120 on both the switches
- shift the ports in to their respective VLAN as per our topology
- configure link between switch 1 and switch 2 as trunk link
- make sure the users of same VLAN on the different switch must communicate with each other.
Switch#configure terminal
Switch(config)#hostname sw1
sw1(config)#vlan 110
sw1(config-vlan)#exit
sw1(config)#vlan 120
sw1(config-vlan)#exit
sw1(config)#interface range FastEthernet 0/1-2
sw1(config-if-range)#switchport mode access
sw1(config-if-range)#switchport access vlan 110
sw1(config-if-range)#exit
sw1(config)#interface range fastEthernet 0/3-4
sw1(config-if-range)#switchport mode access
sw1(config-if-range)#switchport access vlan 120
sw1(config-if-range)#end
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active 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, Gig0/2
110 VLAN0110 active Fa0/1, Fa0/2
120 VLAN0120 active Fa0/3, Fa0/4
1002 fddi-default act/unsup
1003 token-ring-default act/unsup
1004 fddinet-default act/unsup
1005 trnet-default act/unsup
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
1 enet 100001 1500 - - - - - 0 0
110 enet 100110 1500 - - - - - 0 0
120 enet 100120 1500 - - - - - 0 0
1002 fddi 101002 1500 - - - - - 0 0
1003 tr 101003 1500 - - - - - 0 0
1004 fdnet 101004 1500 - - - ieee - 0 0
1005 trnet 101005 1500 - - - ibm - 0 0
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
Remote SPAN VLANs
------------------------------------------------------------------------------
Primary Secondary Type Ports
Switch>enable
Switch#configure terminal
Switch(config)#hostname sw2
sw2(config)#vlan 110
Sw2(config-vlan)#exit
Sw2(config)#vlan 120
Sw2(config-vlan)#exit
Sw2(config)#interface range fastEthernet 0/1-2
Sw2(config-if-range)#switchport mode access
Sw2(config-if-range)#switchport access vlan 110
Sw2(config-if-range)#exit
Sw2(config)#interface range fastEthernet 0/3-4
Sw2(config-if-range)#switchport mode access
Sw2(config-if-range)#switchport access vlan 120
Sw2(config-if-range)#end
Sw2#show vlan
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active 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, Gig0/2
110 VLAN0110 active Fa0/1, Fa0/2
120 VLAN0120 active Fa0/3, Fa0/4
1002 fddi-default act/unsup
1003 token-ring-default act/unsup
1004 fddinet-default act/unsup
1005 trnet-default act/unsup
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
1 enet 100001 1500 - - - - - 0 0
110 enet 100110 1500 - - - - - 0 0
120 enet 100120 1500 - - - - - 0 0
1002 fddi 101002 1500 - - - - - 0 0
1003 tr 101003 1500 - - - - - 0 0
1004 fdnet 101004 1500 - - - ieee - 0 0
1005 trnet 101005 1500 - - - ibm - 0 0
VLAN Type SAID MTU Parent RingNo BridgeNo Stp BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
Remote SPAN VLANs
------------------------------------------------------------------------------
Primary Secondary Type Ports
------- --------- ----------------- ------------------------------------------
HOST 1
host 2 can communicate to host 3 both are in same VLAN 110.
host 3 can communicate with host 1 both are in same VLAN 110, but host 3 can not communicate with host 5 its also in the same VLAN 110, because there is no trunking is configure yet .
sw1(config)#interface fastEthernet 0/10
sw1(config-if)#switchport mode trunk
sw1(config-if)#switchport trunk encapsulation dot1q
sw1(config-if)#switchport trunk allowed vlan 110-120
sw1(config-if)#end
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/10, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/10, changed state to up
sw2(config)#interface fastEthernet 0/10
sw2(config-if)#switchport mode trunk
sw1(config-if)#switchport trunk encapsulation dot1q
sw2(config-if)#switchport trunk allowed vlan 110 120
sw1(config-if)#end
(The ISL method of VLAN identification or trunking encapsulation no longer is supported across all Cisco catalyst switch platform.)
some cisco switch do not have option of ISL. so there is no need to specify encapsulation dot.1q ,
sw1#show interfaces trunk
Port Mode Encapsulation Status Native vlan
Fa0/10 on 802.1q trunking 1
Port Vlans allowed on trunk
Fa0/10 110-120
Port Vlans allowed and active in management domain
Fa0/10 110,120
Port Vlans in spanning tree forwarding state and not pruned
Fa0/10 110,120
sw2#show interfaces trunk
Port Mode Encapsulation Status Native vlan
Fa0/10 on 802.1q trunking 1
Port Vlans allowed on trunk
Fa0/10 110-120
Port Vlans allowed and active in management domain
Fa0/10 110,120
Port Vlans in spanning tree forwarding state and not pruned
Fa0/10 110,120
after configuring trunk between both the switch now host 3 can communicate with host 5.
sw1(config-if)#switchport mode trunk
sw1(config-if)#switchport trunk encapsulation dot1q
sw1(config-if)#switchport trunk allowed vlan 110-120
sw1(config-if)#end
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/10, changed state to down
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/10, changed state to up
sw2(config)#interface fastEthernet 0/10
sw2(config-if)#switchport mode trunk
sw1(config-if)#switchport trunk encapsulation dot1q
sw2(config-if)#switchport trunk allowed vlan 110 120
sw1(config-if)#end
(The ISL method of VLAN identification or trunking encapsulation no longer is supported across all Cisco catalyst switch platform.)
some cisco switch do not have option of ISL. so there is no need to specify encapsulation dot.1q ,
sw1#show interfaces trunk
Port Mode Encapsulation Status Native vlan
Fa0/10 on 802.1q trunking 1
Port Vlans allowed on trunk
Fa0/10 110-120
Port Vlans allowed and active in management domain
Fa0/10 110,120
Port Vlans in spanning tree forwarding state and not pruned
Fa0/10 110,120
sw2#show interfaces trunk
Port Mode Encapsulation Status Native vlan
Fa0/10 on 802.1q trunking 1
Port Vlans allowed on trunk
Fa0/10 110-120
Port Vlans allowed and active in management domain
Fa0/10 110,120
Port Vlans in spanning tree forwarding state and not pruned
Fa0/10 110,120
after configuring trunk between both the switch now host 3 can communicate with host 5.
No comments:
Post a Comment