Apache 模块 mod_lbmethod_heartbeat

Description:mod_proxy_balancer的心跳流量计数负载均衡器调度程序算法
Status:Experimental
Module Identifier:lbmethod_heartbeat_module
Source File:mod_lbmethod_heartbeat.c
Compatibility:在版本 2.3 及更高版本中可用

Summary

lbmethod=heartbeat使用mod_heartmonitor的服务来平衡通过mod_heartbeat模块提供心跳信息的原始服务器之间的平衡。

此模块的负载平衡算法倾向于使用随时间推移具有更多就绪(空闲)容量的服务器,但不会每次都选择具有最就绪容量的服务器。具有 0 个活动 Client 端的服务器将受到惩罚,但前提是它们尚未完全初始化。

HeartbeatStorage Directive

Description:读取心跳数据的路径
Syntax:HeartbeatStorage file-path
Default:HeartbeatStorage logs/hb.dat
Context:server config
Status:Experimental
Module:mod_lbmethod_heartbeat

HeartbeatStorage指令指定读取心跳数据的路径。仅当未加载mod_slotmem_shm时才使用此平面文件。