zoukankan      html  css  js  c++  java
  • 华为交换机配置入门(五)

    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

  • 相关阅读:
    lvs中dr模式配置脚本
    使用AFNetworking第三方下载类
    java 经常使用測试框架
    Qt5的插件机制(1)--Qt 框架中的插件载入机制概述
    leetcode笔记:Merge Sorted Array
    oracle仿全文检索切词机制实现文本信息类似度查找
    hadoop学习;datajoin;chain签名;combine()
    php函数in_array奇怪现象
    Sql_Server中怎样推断表中某列是否存在
    Java Bean 简单介绍及其应用
  • 原文地址:https://www.cnblogs.com/yokingma/p/11125868.html
Copyright © 2011-2022 走看看