07-04-2022 06:42 AM
Hi,
I am trying to configure the following command on a ten gig interface on a 9400 series switch, but it does not work:
switchport trunk allowed vlan add xxxx,xxx,xxx
the command is accepted when i hit enter, but does not show in the running config. instead it is showing as a full trunk.
The interface has been configured as a trunk with a native vlan, so has basic config at the moment.
Please can you advise how i can have the interface accepted pruned vlans ?
Best Regards,
Sabeel
07-04-2022 07:26 AM - edited 07-04-2022 07:27 AM
we need more information, what version of code running :
is that standard VLAN or extended vlan ?
in general below config should work : ( example, replace with correct interface)
vlan 10,20,30
!
interface gigabitethernet 1/0/1
switchport mode trunk
switchport trunk allowed vlan 10,20,30
post output :
show version
show run interfaces gigabitethernet 1/0/1
show interfaces gigabitethernet 1/0/1 switchport
07-04-2022 07:44 AM - edited 07-04-2022 09:13 AM
the SW refuse to pruning range of VLAN from trunk that include the internal VLAN ID.
here you remove all internal VLAN and specify only some VLAN ID.
you need to allow internal VLAN ID and then add some VLAN ID.
the add VLAN must be in range of normal VLAN ID as shown below
07-04-2022 07:46 AM
"switchport trunk allowed vlan add xxxx,xxx,xxx" adds vlans to an existing "switchport trunk allowed vlan xxxx,xxxx" on that interface.
If no "switchport trunk allowed vlan xxxx,xxxx" exists on that port, the "switchport trunk allowed vlan add xxxx,xxx,xxx" command is ignored.
07-04-2022 08:23 AM
Hello @SabeelShakeel00430 ,
it may be simpler
if currently the interface is a trunk carrying all vlans you need to use the command
interface type x/y
switchport trunk allowed vlan X,Y,Z
The usage of the add keyword is thought for a trunk that has already a manual set of VLANs allowed to add one or more VLANs to that set.
if you try to use switchport trunk allowed vlan add to a default trunk you get no change because the VLAN(s) you are adding are already allowed in the range 1.4094 the IEEE 802.1Q usable range of VLANs
Hope to help
Giuseppe
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