cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements
Join Customer Connection to register!
1174
Views
5
Helpful
8
Replies
blanz
Beginner

Cisco Switch 3750 VLan Taggin

I have a client unable to perform VLan tagging attached to a Cisco 3750 switch port X. I assigned a VLan to that port:

Switch(config)# interface gigabitethernet0/1
Switch(config-if)# switchport mode access 
Switch(config-if)# switchport access vlan 2
Switch(config-if)# end
The switch does not broadcast packets sent from the client within the VLan. Now I wonder, if the switch expects the client to tag the packet already? I want the switch to
1) accept the untagged packet on port Gi0/1
2) to tag it with VLan ID 2 and
3) to forward it in the VLan "broadcast domain".
1 ACCEPTED SOLUTION

Accepted Solutions
Reza Sharifi
Hall of Fame Expert

So the switch will tag the packet with vlan 100 once it is received on gi0/1 and forwarded on gi0/1.

If you mean forwarded on g0/2, yes.

If you configure g0/1 as access port with vlan 100, the switch will receive untagged frames from the camera and if you configure 0/2 as trunk and add vlan 100 to it than vlan 100 will be tagged.

HTH

View solution in original post

8 REPLIES 8
Reza Sharifi
Hall of Fame Expert

You have configured port g0/1 with mode access. In this case, whatever device is attached to this port with send packets untagged. If you want it to be tagged with vlan 2 than the mode needs to be changed to trunk and you would need to do the same thing on the end device. 

switchport mode access 

I have a client unable to perform VLan tagging attached to a Cisco 3750 switch port X. I assigned a VLan to that port:
Switch(config)# interface gigabitethernet0/1
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan 2
Switch(config-if)# end
The switch does not broadcast packets sent from the client within the VLan. Now I wonder, if the switch expects the client to tag the packet already? I want the switch to 1) accept the untagged packet on port Gi0/1 2) to tag it with VLan ID 2 and 3) to forward it in the VLan "broadcast domain".

Hi,

In this case, you should configure your switchport into the 802.1Q trunk mode. This will allow the port to receive and send both tagged and untagged frames. The untagged frames will be only the frames that belong to a so-called native VLAN configured on the port. All other VLANs will have their frames tagged.

The configuration could look as follows:

interface gi0/1
switchport trunk encapsulation dot1q
switchport trunk native vlan 100
switchport mode trunk

Hope that Helps..

-GI

Thank You!

So mode access only accepts tagged packets and will reject other packets? When I use the configuration you pasted, the switch will be able to receive untagged packets on port gi0/1 and tag them with the native vlan 100 if forwarded via another trunk link?

No. A switch port configured as access will accept only untagged frames. Tagged frames are received and are sent on trunk ports.

If a trunk port receives an untagged frame it will treat that frame as belonging to the native vlan and will forward that frame untagged to other ports on the switch that belong to that vlan. If the switch is to forward this frame out a port that is configured as a trunk port then we need to know what is the native vlan on that second trunk.

So if I am understanding correctly your example the switch will have gi0/1 configured as trunk and  will receive receive an untagged frame which it treats as belonging to native vlan 100. If the switch is forwarding to another port in vlan 100 it will forward the frame untagged. If the switch is forwarding the frame out gi0/11 which is configured as trunk with native vlan 100 then it forwards the frame untagged. But if gi0/11 is configured with native vlan as 50 then the frame in vlan 100 will be sent tagged.

HTH

Rick 

HTH

Rick

Thank You!

My initial example was different.

I have a client device A - a network camera. It will only sent untagged frames. It is connected to a Cisco 3750 on port Gi0/1. On port Gi0/2 I forward those packets on a trunk link. I want packets initially sent from A to be tagged with VLan 100 when sent via trunk on Gi0/2.

Sorry, I'm quite new to this topic and hopefully found an understandable wording.

Reza Sharifi
Hall of Fame Expert

Than in this case port g0/1 should be configured as access port for the camera and port g0/2 as trunk with spesific vlans you want (e,g 2,3,...).

HTH

So the switch will tag the packet with vlan 100 once it is received on gi0/1 and forwarded on gi0/1. Is that correct?

Reza Sharifi
Hall of Fame Expert

So the switch will tag the packet with vlan 100 once it is received on gi0/1 and forwarded on gi0/1.

If you mean forwarded on g0/2, yes.

If you configure g0/1 as access port with vlan 100, the switch will receive untagged frames from the camera and if you configure 0/2 as trunk and add vlan 100 to it than vlan 100 will be tagged.

HTH

View solution in original post