• 华为交换机配置入门(五)


    VLAN配置

    1、创建VLAN

    拓扑图

    SW1配置:

    <Huawei>system-view
    [Huawei]sysname S1
    [S1]vlan 10
    [S1-vlan10]vlan 20

    [S1]display vlan
    The total number of vlans is : 3
    --------------------------------------------------------------------------------
    U: Up; D: Down; TG: Tagged; UT: Untagged;
    MP: Vlan-mapping; ST: Vlan-stacking;
    #: ProtocolTransparent-vlan; *: Management-vlan;
    --------------------------------------------------------------------------------

    VID Type Ports
    --------------------------------------------------------------------------------
    1 common UT:Eth0/0/1(U) Eth0/0/2(U) Eth0/0/3(U) Eth0/0/4(D)
    Eth0/0/5(U) Eth0/0/6(D) Eth0/0/7(D) Eth0/0/8(D)
    Eth0/0/9(D) Eth0/0/10(D) Eth0/0/11(D) Eth0/0/12(D)
    Eth0/0/13(D) Eth0/0/14(D) Eth0/0/15(D) Eth0/0/16(D)
    Eth0/0/17(D) Eth0/0/18(D) Eth0/0/19(D) Eth0/0/20(D)
    Eth0/0/21(D) Eth0/0/22(D) GE0/0/1(D) GE0/0/2(D)

    10 common
    20 common

    VID Status Property MAC-LRN Statistics Description
    --------------------------------------------------------------------------------

    1 enable default enable disable VLAN 0001
    10 enable default enable disable VLAN 0010
    20 enable default enable disable VLAN 0020

    SW2配置:

    <Huawei>system-view 
    [Huawei]sysname S2
    [S2]vlan batch 30 40

    [S2]display vlan
    The total number of vlans is : 3
    --------------------------------------------------------------------------------
    U: Up; D: Down; TG: Tagged; UT: Untagged;
    MP: Vlan-mapping; ST: Vlan-stacking;
    #: ProtocolTransparent-vlan; *: Management-vlan;
    --------------------------------------------------------------------------------

    VID Type Ports
    --------------------------------------------------------------------------------
    1 common UT:Eth0/0/1(U) Eth0/0/2(U) Eth0/0/3(D) Eth0/0/4(D)
    Eth0/0/5(U) Eth0/0/6(D) Eth0/0/7(D) Eth0/0/8(D)
    Eth0/0/9(D) Eth0/0/10(D) Eth0/0/11(D) Eth0/0/12(D)
    Eth0/0/13(D) Eth0/0/14(D) Eth0/0/15(D) Eth0/0/16(D)
    Eth0/0/17(D) Eth0/0/18(D) Eth0/0/19(D) Eth0/0/20(D)
    Eth0/0/21(D) Eth0/0/22(D) GE0/0/1(D) GE0/0/2(D)

    30 common
    40 common

    VID Status Property MAC-LRN Statistics Description
    --------------------------------------------------------------------------------

    1 enable default enable disable VLAN 0001
    30 enable default enable disable VLAN 0030
    40 enable default enable disable VLAN 0040

    端口配置

    [S1]interface Ethernet0/0/1
    [S1-Ethernet0/0/1]port link-type access
    [S1-Ethernet0/0/1]port default vlan 10
    [S1-Ethernet0/0/1]qu
    [S1]interface Ethernet0/0/2
    [S1-Ethernet0/0/2]port link-type access
    [S1-Ethernet0/0/2]port default vlan 10
    [S1-Ethernet0/0/2]qu
    [S1]interface Ethernet0/0/3
    [S1-Ethernet0/0/3]port link-type access
    [S1-Ethernet0/0/3]port default vlan 20
    [S1-Ethernet0/0/3]qu

    [S2]interface Ethernet0/0/1
    [S2-Ethernet0/0/1]port link-type access
    [S2-Ethernet0/0/1]port default vlan 30
    [S2-Ethernet0/0/1]qu
    [S2]interface Ethernet0/0/2
    [S2-Ethernet0/0/2]port link-type access
    [S2-Ethernet0/0/2]port default vlan 40
    [S2-Ethernet0/0/2]qu

    查看vlan

    [S1]display vlan
    The total number of vlans is : 3
    --------------------------------------------------------------------------------
    U: Up; D: Down; TG: Tagged; UT: Untagged;
    MP: Vlan-mapping; ST: Vlan-stacking;
    #: ProtocolTransparent-vlan; *: Management-vlan;
    --------------------------------------------------------------------------------

    VID Type Ports
    --------------------------------------------------------------------------------
    1 common UT:Eth0/0/4(D) Eth0/0/5(U) Eth0/0/6(D) Eth0/0/7(D)
    Eth0/0/8(D) Eth0/0/9(D) Eth0/0/10(D) Eth0/0/11(D)
    Eth0/0/12(D) Eth0/0/13(D) Eth0/0/14(D) Eth0/0/15(D)
    Eth0/0/16(D) Eth0/0/17(D) Eth0/0/18(D) Eth0/0/19(D)
    Eth0/0/20(D) Eth0/0/21(D) Eth0/0/22(D) GE0/0/1(D)
    GE0/0/2(D)

    10 common UT:Eth0/0/1(U) Eth0/0/2(U)

    20 common UT:Eth0/0/3(U)


    VID Status Property MAC-LRN Statistics Description
    --------------------------------------------------------------------------------

    1 enable default enable disable VLAN 0001
    10 enable default enable disable VLAN 0010
    20 enable default enable disable VLAN 0020

    [S2]dis vlan
    The total number of vlans is : 3
    --------------------------------------------------------------------------------
    U: Up; D: Down; TG: Tagged; UT: Untagged;
    MP: Vlan-mapping; ST: Vlan-stacking;
    #: ProtocolTransparent-vlan; *: Management-vlan;
    --------------------------------------------------------------------------------

    VID Type Ports
    --------------------------------------------------------------------------------
    1 common UT:Eth0/0/3(D) Eth0/0/4(D) Eth0/0/5(U) Eth0/0/6(D)
    Eth0/0/7(D) Eth0/0/8(D) Eth0/0/9(D) Eth0/0/10(D)
    Eth0/0/11(D) Eth0/0/12(D) Eth0/0/13(D) Eth0/0/14(D)
    Eth0/0/15(D) Eth0/0/16(D) Eth0/0/17(D) Eth0/0/18(D)
    Eth0/0/19(D) Eth0/0/20(D) Eth0/0/21(D) Eth0/0/22(D)
    GE0/0/1(D) GE0/0/2(D)

    30 common UT:Eth0/0/1(U)

    40 common UT:Eth0/0/2(U)


    VID Status Property MAC-LRN Statistics Description
    --------------------------------------------------------------------------------

    1 enable default enable disable VLAN 0001
    30 enable default enable disable VLAN 0030
    40 enable default enable disable VLAN 0040

  • 相关阅读:
    玩转Android状态栏
    自己制作 Android Vector Asset 矢量图
    android studio配置模拟器
    Android数据库使用指南(下)
    Android数据库使用指南(上)
    四种常见的 POST-------- content-type数据提交方式
    json格式化
    js删除cookie的方法
    js中box和box()的区别
    synchronized加static区别
  • 原文地址:https://www.cnblogs.com/yokingma/p/11125868.html
Copyright © 2020-2023  润新知