Bitmindframes cisco study guides.
TRUNKING
Trunking is Point to point link from a switch to a router or a switch. A trunk link can carry traffic from multiple vlans over a single link allowing vlans to span internetworks.
Cisco supports IEEE 802.1Q trunking on 100/1000 ethernet
What does trunking solve?
Without trunking switches & routers have to be interconnected with a separate link for each VLAN. 4 VLANs require 4 links connecting switches S1 & S2 leaving fewer ports for devices. If S2 was connected to S1 it would be more than 4 ports.
802.1Q frame tagging
Switches use Ethernet frames to forward packets. The frame has no field for vlan ID.
802.1q adds a tag to the frame identifying the vlan. Before a switch sends a frame out a trunk port it takes the frame apart & inserts a vlan tag & redoes the FCS.
Ethertype field = 0×8100(tag protocol ID or TPID value)
With the type 8100, the switch receiving the frame knows tag control info field.
The tag control info field contains:
3 bits of user priority
1 bit of canonical format identifiers
12 bits vlan ID
Native vlan’s & 802.1q trunking
Some trunking devices tag native vlan traffic
Control traffic sent on the native vlan should be untagged
If a dot1q trunk receives a tagged frame on the native vlan, it drops it. So config non-compliant equipment!
When a cisco trunk port receives untagged frames it forwards them to the native vlan #1 by default
The native vlan = PORT VLAN ID (PVID e.g. 99)
TRUNKING MODES
802.1q trunking replaced a cisco legacy trunking protocol
called ISL inter switch link
A 1.q trunk port supports tagged/untagged traffic
all untagged traffic & traffic tagged with a null VID are assumed to belong to PVID
DYNAMIC TRUNKING PROTOCOL
A cisco protocol enabled on a port when certain trunking modes are configured
DTP manages trunk negotiation if the port on the other switch is configured in a trunk mode that supports dtp
Supports both ISL & 1.q
Switches do not need DTP to do trunking
TRUNKING MODES
All modes except off will send out DTP advertisements
(ON by default)
Set with: switchport mode trunk
Dynamic auto
Set with: switchport mode dynamic auto
Dynamic desireable
Set with: switchport mode dynamic desireable
DTP off
if DTP is off no advertisements are sent
set with: switchport nonnegotiate
CONFIGURING VLANS & TRUNKS
1.Create vlans
2.Assign ports to vlans
3.verify vlan config
4.enable trunking on inter-switch & switch router links
5.verify trunk configs
Verifying VLAN & port membership
R1#Show vlan
R1#Show vlan brief
R1#Show vlan name
R1#Show vlan summary
R1#Show interfaces vlan #
R1#Show interfaces x/x
MANAGING PORT MEMBERSHIP
to reassign a port to vlan1
R1(conf-if)#no switchport access vlan #
This removes the port from the vlan but does not delete the vlan
A static access port can only have 1 vlan
to change vlan membership just reassign the vlan with
R1(conf-if)#switchport access vlan #
DELETING VLANS
R1(config)#no vlan vlan-id
Delete the entire vlan.dat with flash:vlan.dat
Before deleting a vlan first reassign all member ports!!!
Any ports not moved to an active vlan are unable to communicate with other stations after you delete the vlan
Configuring trunking
R1(conf-if)#switchport mode trunk
The interface changes to permanent trunking mode & enters DTP negotiation
To specify a native vlan other than 1
R1(conf-if)#switchport mode trunk native vlan #
To allow a limited # of vlans access to trunk use:
R1(conf-if)#switchport mode trunk allowed vlan add #
To reset the allowed vlans & native vlan
R1(conf-if)#no switchport trunk allowed vlan
R1(conf-if)#no switchport trunk native vlan #
PROBLEMS WITH TRUNKS
Native vlan mismatches
Trunk mode mismatches
Allowed vlans on trunks