01-30-2014 07:56 PM - edited 03-07-2019 05:55 PM
Hi,
IF we make a port as a part of vlan all the frames belong to that vlan will be tagged. So even if we make a port as a part of vlan how can we make it as untagged. Whether the ports in VLAN 1, native vlan will be tagged with vlan 1 or it's empty. Which command do we use to untagged the port.
PLease clarify.
Thanks in advance,
Naveen
01-30-2014 08:54 PM
If the port is set to access then the frames are sent untagged. Frames sent on trunk ports are tagged except for the native VLAN by default. It is possible to have different native VLANs on different trunks on the switch.
It is also possible to tag the native VLAN with the vlan dot1q tag native command.
Daniel Dib
CCIE #37149
Please rate helpful posts.
01-31-2014 01:47 AM
Once I was forced (at gunpoint) to start working on non Cisco kit (HP, Netgear etc), I struggled to pickup the concept of tagged and untagged at first.
Access port = Untagged
Trunk port = Tagged
I always think about it from the perspective of the host itself.
If the host connected to the switchport it capable of tagging packets with the Vlan ID, the port can be tagged.
If the host is unable to tag packet with the Vlan ID (i.e its a PC or printer etc) then it will be an untagged port
An untagged port will add the Vlan ID to the header of each packet it recieves from the host.
A tagged port will expect to receive frames with the Vlan ID already in the frames header. Any frames it receives without a Vlan ID in the header, will be tagged with the native Vlan ID.
Hope this helps
02-02-2014 08:14 PM
Hi Devils,
Thanks for the clarification
And the commands to make the ports tagged and untagged is "Switch port mode trunk" for tagged and "switch port mode access" for un tagged port right ? in cisco switches or do we need to add any other commands.
02-02-2014 10:16 PM
! Trunk
interface x/x
switchport trunk encapsulation dot1q
switchport mode trunk
Encapsulation does not need to be set if switch only supports Dot1q, older devices support ISL as well. The port can also be set to dynamic desirable or auto but if you want a trunk it is better to hard code it.
Switch also use Dynamic Trunking Protocol (DTP). This can be turned off with switchport nonegotiate if you don't want it enabled. Then it's also possible to change the native VLAN if wanted and it's also possible to tag the native VLAN.
! Access
interface x/x
switchport mode access
switchport access vlan x
To confirm which mode the port is configured for and what mode it's actually running in use the show interface x/x switchport command.
Daniel Dib
CCIE #37149
Please rate helpful posts.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide