• 交换机基础配置之结合以太通道的vlan设置


    我们将以上面的拓扑图来做实验,建立以太通道,并设置好vlan,将pc1和pc3放在同一vlan,将pc2和pc4放在同一vlan,同一vlan能跨交换机通信

    在一切还没布置之前,四台pc机都在同一网段,都是可以互相通信的

    先给pc机都配置好ip地址

    配置switch1

    enable  进入特权模式

    configure terminal  进入全局配置模式

    interface port-channel 2  设置并创建以太通道,二层交换机的组号为1-6,三层为1-48

    switchport mode dynamic desirable

    exit

    port-channel load-balance?(?可以告诉你选项的作用)这里会出现6种选项,是实现以太通道负载均衡的方式

    port-channel load-balance dst-mac  选择以目标mac地址的方式实现负载均衡

    vlan 10  创建好vlan

    vlan 20

    interface f0/3

    channel-group 2 mode on

    exit

    interface f0/4

    channel-group 2 mode on

    exit

    interface f0/1

    switchport mode access

    switchport access vlan 10  

    exit

    interface f0/2

    switchport mode access

    switchport access vlan 20

    exit

    interface port-channel 2

    switchport mode trunk  设置vlan的中继

    接下里在switch2中进行配置

    enable  

    configure terminal  

    interface port-channel 2  

    switchport mode dynamic desirable

    exit

    port-channel load-balance dst-mac  

    vlan 10  创建好vlan

    vlan 20

    interface f0/1

    channel-group 2 mode on

    exit

    interface f0/2

    channel-group 2 mode on

    exit

    interface f0/3

    switchport mode access

    switchport access vlan 10  

    exit

    interface f0/4

    switchport mode access

    switchport access vlan 20

    exit

    interface port-channel 2

    switchport mode trunk 

    这样配置就全部完成了,以太通道搭建完毕,同时完成了负载均衡,并且同vlan可以跨交换机通信

  • 相关阅读:
    .NET Core SignalR 和 .NET SignalR 区别
    MySQL 连接出现 Authentication plugin 'caching_sha2_password' cannot be loaded
    Geohash 基本知识及 .NET 下计算相邻8个区域编码
    ASP.NET 下配置请求大小、请求时间等参数
    .NET Core、EF、Dapper、MySQL 多种方式实现数据库操作(动态注册实体类)
    .NET Core 开发常用命令(VS Code)
    ping
    exec与xargs区别
    doc转docx
    读取docx表格中的信息
  • 原文地址:https://www.cnblogs.com/wuhaohao/p/9178434.html
Copyright © 2020-2023  润新知