switchport trunk vs switchport mode access/trunk

Unanswered Question
Dec 20th, 2004
User Badges:

I am studying for the CCNA exam and was wondering if somebosy could please shed the light on the difference between the switchport trunk vs switchport mode access/trunk as far as trunking is concerned on the 2950 switch?


  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (3 ratings)
ccie12933 Mon, 12/20/2004 - 13:43
User Badges:
  • Silver, 250 points or more

By default, switch ports are in "dynamic desirable" mode, which means they're actively attempting to trunk.

If a port is going to belong to a specific vlan, you can use "switchport mode access" to make that port an unconditional access port. This port will be assigned to a single vlan.

If you set a port to "switchport mode trunk", the port is now unconditionally a trunk port.

If a port is by default in "dynamic desirable" mode, why bother making it a trunk port? One reason is to prevent the sending of Dynamic Trunking Protocol frames. These frames are sent by ports in dynamic desirable, but not in trunking mode. (Some devices don't handle DTP frames correctly.)

Chris Bryant

CCIE #12933


axfalk Mon, 12/20/2004 - 17:27
User Badges:

Chris, thanks for your response. So, if I a port is going to be a trunk, can I define it using the "switchport trunk" command as opposed to the "swithport mode trunk" command? - what would be the difference?

Thanks again.


I think your confusion lies in the fact that switchport mode trunk and switchport trunk are two different commands that are interelated.

As Chris highlighted earlier, on IOS based switches the default is that the port is by default in desirable mode - this means that the port will generate DTP frames and will attempt to negotiate a trunk if the other end is set to desirable, auto or on. (incidentally the default on CATos is Auto).

With the command switchport mode trunk you can define whether the trunk will be one of the following:






There are a number of combinations that work and a number that do not - check out CCO for the combinations.

The switchport trunk command is used to define the encapsulation type of the trunk. This command can also be used to define the VLAN's that are allowed across the trunk. Syntax for this command is:

switchport trunk encapsulation dot1q (for 802.1q encapsulation)

switchport trunk allowed vlan remove 2-1001 (clears all the vlans that are allowed across the trunk)

switchport trunk allowed vlan add 10-20 (only now allows vlan's 10 to 20 across the trunk)

Hope this helps


axfalk Tue, 12/21/2004 - 07:56
User Badges:

Simon, thanks - it has clarified it for me. Just a follow-up ? please, if you do not mind. If a port is defined as a trunk port via the "switchport mode trunk" command, would I be able to assign a VLAN to that port or I could only assign a VLAN to a port that's in access mode?

thanks again.

ccie12933 Tue, 12/21/2004 - 08:47
User Badges:
  • Silver, 250 points or more

:: jumping back in :::

Once a link is a trunk port, you can't assign a VLAN to it.

Simon left some great links for you to read. The different combinations seem a little complicated at first, but they're not that bad.

Chris Bryant

CCIE #12933


alexander0943 Wed, 07/01/2015 - 16:26
User Badges:

I have a question hope you can reply to it

Well I have IP-Phones on the same network and most of them are Wireless and local computer are also Wireless


So my question is


do I need to make all ports access ports or do I need to make them trunk, Now I want to assign different IP to the phone from the computer so should have 2 Vlan's one name VOICE and the other name DATA and sinces the phones are Wireless and connect get IP from the same Wireless AP how do I make the phone to get dirferent IP from the computer



Vlan VOICE = gateway the IP of the Vlan

Vlan DATA = gateway the IP of the Vlan


Running DHCP from the Catalyst 3560 E POE

Wireless AP Cisco


NO Wireless Controller


thank you so much for your help




This Discussion