华为交换机S5700-52C-SI配置vlan

环境准备:通过超级终端Hyper Terminal和console串口线链接华为交换机,用9600波特率链接

添加vlan

<Quidway>system-view                                             #由用户视图进入系统视图

[Quidway]vlan 1  /创建并进入vlan1                    

[Quidway-vlan1]interface GigabitEthernet0/0/1   #默认将全部端口加入到vlan1

[Quidway-vlan1]interface Vlanif 1

[Quidway-Vlanif1]ip address 172.16.72.254 255.255.255.0

[Quidway-Vlanif1]ip route-static 0.0.0.0 0.0.0.0 172.16.72.1

[Quidway-Vlanif1]quit

[Quidway]Exit

<Quidway>display current-configuration   #查看当前配置

修改vlan

参考链接:https://blog.csdn.net/shangcx/article/details/71429857

<Quidway>system-view                                             #由用户视图进入系统视图

[Quidway]vlan 2  /创建并进入vlan2

[Quidway-vlan2]port GigabitEthernet 0/0/46 to 0/0/48    #添加46-48端口到vlan2   

[Quidway-vlan2]dis vlan
Error: Trunk or Hybrid port(s) can not be added or deleted in this manner.  #报错:不能添加Hybrid 混合端口

需要将端口模式改为access模式才可以继续       

Access、Hybrid和Trunk三种模式的理解 :https://blog.csdn.net/liunianchao/article/details/50000055

[Quidway-vlan2]int GigabitEthernet 0/0/46
[Quidway-GigabitEthernet0/0/46]port link-type access
[Quidway-GigabitEthernet0/0/46]quit
[Quidway]int GigabitEthernet 0/0/47
[Quidway-GigabitEthernet0/0/47]port link-type access
[Quidway-GigabitEthernet0/0/47]quit
 #进入每一个端口将Hybrid模式改为access模式  ... ...

[HuaWei-S5700-01-vlan2]port GigabitEthernet 0/0/46 to 0/0/48                  
HuaWei-S5700-01]dis vlan     # 查看端口   

[Quidway-vlan2]interface Vlanif 2

[Quidway-Vlanif2]ip address 172.16.78.1 255.255.0.0  #配置vlanif ip地址

Info: A similar IP subnet already exists. Please verify the current IP subnet de

sign.

[Quidway-Vlanif2]display current-configuration

删除vlan

参考链接1:https://blog.csdn.net/qq_43640414/article/details/84531868

参考链接2:https://zhidao.baidu.com/question/327349557.html

<Quidway>system-view

[Quidway]dis vlan

[Quidway]interface GigabitEthernet 0/0/47

[Quidway-GigabitEthernet0/0/47]display this
interface GigabitEthernet0/0/47 port link-type access port default vlan 2 return [Quidway-GigabitEthernet0/0/47]undo port default vlan [Quidway-GigabitEthernet0/0/47]display this interface GigabitEthernet0/0/47 port link-type access return [Quidway-GigabitEthernet0/0/47] [Quidway-vlan1]int GigabitEthernet 0/0/48 [Quidway-GigabitEthernet0/0/48]port link-type access [Quidway-GigabitEthernet0/0/48]quit [Quidway] # 直接进行下面两步骤即可 [Quidway]undo interface Vlanif 2 Info: This operation may take a few seconds. Please wait for a moment...succeeded. [Quidway]undo vlan 2 [Quidway]dis vlan

 

上一篇:《自拍教程47》Python_adb重启设备100次


下一篇:MySQL数据库安装后的安全设置