linux运维-team链路聚合

team:
   1.team也是链路聚合的一种方式
     a.最多支持八块网卡
     b.支持模式:广播、轮询、主备、负载均衡


   nmcliconnection add con-name team0 ifname team0 type team config'{"runner":{"name":"activebackup"}}' ip4 172.25.254.122/24 
                       ————        ——        ———
                        连接名        接口名        设备类型

    ##创建一个名为team0并且属性为team的链路接口,并为team0配置ip地址和网关
linux运维-team链路聚合


    nmcli connection add con-name eth0ifname eth0 type team-slave master team0        ##将eth0的网卡口添加到teaam0接口


linux运维-team链路聚合   

 nmcli connection add con-name eth1ifname eth1 type team-slave master team0     ##将eth1的网卡口添加到teaam0接口
linux运维-team链路聚合   

 

 teamdctl team0 stat
linux运维-team链路聚合


执行监控命令:watch -n teamdctl team0 stat  ##用teamdctl命令检查主动备份配置功能

linux运维-team链路聚合
打开一个命令窗口执行:
ping 172.25.254.250
测试:
 

         ifconfig eth0 down     ##当将网卡eth0关掉时,eth1会顶替上,过程中网一直通
    linux运维-team链路聚合

    linux运维-team链路聚合

         ifconfig eth0 up       ##当将eth0重新开启的时候,eth1会依然正常工作,eth0处会在备用状态
    linux运维-team链路聚合

    linux运维-team链路聚合