怎么在华为交换机的所有端口上设置同一个命令啊,一个端口一个端口的设置太麻烦了

来源:百度知道 编辑:UC知道 时间:2024/06/01 11:20:52
大家好,我要在华为3100上配置一个端口策略,但是只能一个端口一个端口的设置,请问有什么好的办法吗?能够一次设置一组端口。谢谢啦
谢谢各位的解答,ahtlycx你给的答案是思科交换机的配置命令,华为的不识别,我把问题再详细说一下吧。我是想在华为交换机上所有端口加上这些命令,stp edged-port enable

loopback-detection enable

port-security max-mac-count 1

port-security port-mode autolearn

port-security intrusion-mode disableport-temporarily
就是在端口上加上安全策略,我现在只能一个端口一个端口的加,好麻烦啊,怎么才能一次性加上啊?有谁知道啊?谢谢了

[xijiaobian]port-group
group-member g0/0/1 to g0/0/40

[xijiaobian-port-group]port link-type access

interface range fastEthernet 0/2 – 48
将fastEthernet 0/2 – fastEthernet 0/48口统一设置。
比如:
端口vlan的划分:
interface fa0/1
switchport accsee vlan 5
interface range fastEthernet 0/2 – 48
switchport access vlan 6
这样就将fastEthernet 0/2 – fastEthernet 0/48都一起划到VLAN 6 去了。