Cisco Command : What is the difference between switchport mode trunk from switchport trunk allowed vlan all?

Jung Torres
Jung Torres used Ask the Experts™
on
does "switchport mode trunk" command allow all vlan by default or I do I need to issue "switchport trunk allowed vlan all" ?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Don JohnstonInstructor
Top Expert 2015

Commented:
switchport mode trunk makes an interface a trunk port (can carry multiple VLANs).

By default, all VLANs are allowed on a trunk port.  

So no, you do not need to issue a "switchport trunk allowed vlan all".  Unless a prior command was issued to restrict the allowed VLAN's.

Author

Commented:
I see,
from show run command, this is what I'm seeing on the interface.
Switchport trunk allowed vlan 1,10
switchport mode trunk

Does this allow only vlan 1 and 10 or does it allow all vlans because of the command "switchport mode trunk"?
Instructor
Top Expert 2015
Commented:
Does this allow only vlan 1 and 10 or does it allow all vlans because of the command "switchport mode trunk"?

Only VLAN's 1 and 10 are allowed on the trunk.

"switchport mode trunk" is what makes the port a trunk.

If the "switchport trunk allowed vlan 1,10" were not there, then all VLAN's are allowed.

Author

Commented:
Great.  I really appreciate your assistance :)

Author

Commented:
Thank You :)

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial