cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1586
Views
0
Helpful
5
Replies

How the switch differentiate between a tagged and a untagged frame?

xiaojun-he
Level 1
Level 1

On a dot1q trunk,the switch can sent untagged frames in the native vlan and tagged frames in the other vlans, the peer switch how to differentiate the received framed is tagged or untagged? Thers are not any indication bits in the frame header either in the original or dot1q frame format that show "I" am untagged or tagged ?

5 Replies 5

mchoo2005
Level 1
Level 1

Tagged frames basically those originating from a specific VLAN. Say a desktop PC connected to VLAN 2 puts a frame into the wire. When the switch receives the frame, it knows that the traffic has to go into VLAN 2. So, it TAGS the frame with VLAN 2's ID.

Untagged frames are those frames that do not originate from a specific VLAN. When a switch receives (in some cases, generates) such a frame, it puts the frame into the native/management VLAN. Examples of untagged frames: BPDU, CDP, broadcast/multicast frames.

So, really, when a switch receives a frame from one of its trunk links, it does not care if the frame is tagged or not. As far as it's concerned, the frame belongs to a certain VLAN, and it knows what to do with it. If it's a tagged frame, then the switch will forward the frame based on the destination MAC address found in the frame header. If it's an untagged frame, then depending on the nature of the frame, the switch will either ignore/drop the frame, forward/flood it, or respond to the frame's originator.

HTH.

xiaojun-he
Level 1
Level 1

That is, as to a received frame, How the peer switch make certain that the two bytes after the "source mac address" is a "TPID" field (belong to dot1q tag) or a "Type/Length" field (belong to untaged Ethernet frame )?

Hi,

In dot1q we use 4 bytes for tagging whihc is also called as internal tagging. Now out of 4 bytes 2 bytes are used as TPID (tag protocol identifier ) which is denoted bu 0x8100. Out of remaining 16 bits 12 bits are used for VlanID and 3 bits are used for COS. Remaining 1 bit is used for canonical format i.e the frames recevied out of length.

Now when 2 switches are trunked together they are aware of their native vlan (bydefault 1) and doesnot tag the frames as they pas on the trunk. While the other remaining vlan frames are tagged. Now switch whihch is receiving the frames at the other end knows that the native vlan is 1 so the frames with this Vlan ID will be untagged and the frames with any other Vlan ID's are tagged, as it sees the Vlan ID carried in the dot1q tag.

HTH,

-amit singh

Thanks.

... Now switch which is receiving the frames at the other end knows that the native vlan is 1 so the frames with this Vlan ID will be untagged...

Will the frame that belong to the native vlan be send on the trunk also with a dot1q tag which VlanID field will be set to be the native-vlan-id?

If so, how can we say the native vlan is untagged?

That is, as to a received frame, How the receiving switch make certain that the two bytes after the "source mac address" is a "TPID" field (belong to dot1q tag) or a "Type/Length" field (belong to untaged Ethernet frame )?

Review Cisco Networking for a $25 gift card