Show Table of Contents
5.4. 了解网络成组守护进程及“运行程序”
成组守护进程
teamd 使用 libteam 控制成组驱动器中的一个实例。这个成组驱动器实例添加硬件设备驱动程序实例以构成网络链接“成组”。这个成组驱动器为内核的其他部分提供网络接口,比如 team0。文档中会为由成组驱动程序实例创建的接口按顺序命名,比如 team0、team1 等等。这样便于理解,但可使用其他名称。teamd 采用在所有成组方法中通用的逻辑;不同负载分享及备份方法中特有的功能,比如轮询,则是由不同的代码单位,也称“运行程序”实施。因为类似 “模块” 和 “模式” 等词语有与内核相关的特别含义,所以选择“运行程序”代表这些代码单元。用户可在 JSON 形式的配置文件中指定运行程序,然后就会在创建实例时将其代码编译到 teamd 实例中。运行程序不是插件,因为运行程序的代码是在创建该程序时编译到 teamd 中。以后可能会有将代码作为 teamd 插件创建的需求。
可在编写时使用以下运行程序。
- broadcast(可将数据传送到所有端口)
- round-robin(可按顺序将数据传送到所有端口)
- active-backup(使用一个端口或链接时其他则处于备用状态)
- loadbalance(使用主动 Tx 负载平衡及基于 BPF 的 Tx 端口选择程序)
- lacp(采用 802.3ad 链接合并控制协议)
此外还可使用以下链接监视程序:
代码中没有对使用具体运行程序防止使用特定链接监视程序的限制,但使用 lacp 运行程序时,只推荐使用 ethtool 链接监视程序。
- ethtool(Libteam lib 使用 ethtool 监视链接状态变化)。若没有在配置中指定其他链接监控程序,则默认使用该程序。
- arp_ping(使用 arp_ping 程序监控使用 ARP 数据包的远端硬件地址状态。)
- nsna_ping(使用
IPv6邻居发现协议中的的邻居播发和邻居请求给你监控邻居的接口状态。)

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.