trunk link - frames entering trunk link will be sent with VLAN tag.
access link - frames entering access link will be sent untagged.
The switch ports of a trunk link are trunk ports, the switch ports of the access link are access ports.
A frame received on an access port (i.e., sent from a host) is not VLAN tagged. It is the switch that tags the frame (with the VLAN number that is assigned to the receiving access port). If it needs to send that frame out on the trunk port. If the frame is destined for another access port, the frame is not tagged.
If a frame comes in on a trunk port it should already be tagged with a VLAN number (unless it is in the native VLAN which is not tagged). The switch then strips the VLAN tag and sends it out on the appropriate access port (or ports if broadcast) to its destination.
Depends on the model, the switch port is by default dynamic auto.
we can change the switch port mode to trunk to allows all vlans(pretagged) traffic to flow to and from it. It is most common to use 802.1q as vlan tagging method.
int fa0/0
switchport mode trunk
switchport trunk encapsulation dot1q
We can also change the switch port mode to access then assign a VLAN ID to this port.
int f0/1
switchport mode access
switchport access vlan 10
Here is an cisco lab configuring both access port and trunk port.
No comments:
Post a Comment