07-08-2014 05:15 AM
hi there,
i have a quick question about the interface range command within a CLI template.
when using the command
interface range gigabitEthernet 1/0/1 - 4
switchport access vlan 900
switchport mode access
no snmp trap link-status
no logging event link-status
it seems to only apply the options to the first interface and not the entire range.
just wondering if someone could help
the target ios device is 2960x with IOS 15.x
thanks for any help
07-08-2014 11:13 AM
Ideally it should work. Did you tried using the range command without spaces?
You have "gi 1/0/1 - 4", please try without space "gi 1/0/1-4" and see how the template goes.
-Thanks
Vinod
07-08-2014 11:19 AM
Yes, I've tried many variations, but to no avail.
any help would be appreciated
regards
07-08-2014 06:13 PM
I just tried creating a CLI template with the following config and pushing it to one of our 2960X switches and it worked:
in ra g1/0/5 - 10
description TestWorked
end
Here was the result:
#sho inter status
Port Name Status Vlan Duplex Speed Type
Gi1/0/1 notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/2 notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/3 notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/4 notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/5 TestWorked notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/6 TestWorked notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/7 TestWorked notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/8 TestWorked connected 2 a-full a-10 10/100/1000BaseTX
Gi1/0/9 TestWorked notconnect 2 auto auto 10/100/1000BaseTX
Gi1/0/10 TestWorked connected 2 a-full a-10 10/100/1000BaseTX
07-09-2014 06:06 AM
I've made a little progress. it seems when deploying the template via configuration tasks the command works as it should. However, i'm trying to deploy my CLI template via PnP profile (auto install), its during this method that the configuration only applies to the first interface of the range. is there are a known bug for this or a work around?
regards
Roy
07-09-2014 06:20 AM
I have also tested this and seems it worked. With your issue specific to PnP during which Interface Range is not working, this doesn't seems anything known.
It may be a new Bug possibly. I would advise you to open a TAC case to work on this further to identify this issue.
-Thanks
Vinod
06-13-2015 07:13 PM
Hi Roy,
were you ever able to resolve? im having the same issue using it via PnP.
Thanks in advance for the responses
06-15-2015 12:17 PM
I was never able to solve the issue using the interface range command. if you happen to find a solution please message me
thanks
Roy
06-15-2015 12:34 PM
Yeah well i did a little bit of a workaround but may not be acceptable. Im using autosmart ports. Works for now but i know CDP isnt supposed to be on post configs. I may just edit the macro once the phones are plugged in and leave the configs there.
Im also having an auto configure issue for the trunks so i may hardcode as well.
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