Bug #8586
closedGateway Group trigger level
100%
Description
Hi to all,
i think there is a problem using trigger level in gateway group other than "member down".
In function "return_gateway_groups_array" in file "/etc/inc/gwlb.inc" there is a check over the gateway group trigger, but it cannot work, because in config the trigger is saved as integer (0, 1, 2, 3) while the check try to find word ("loss", "latency").
Someone can confirm that?
CONFIG
Array ( [0] => Array ( [name] => GW_WAN_GROUP_01 [item] => Array ( [0] => WAN_UMTSGW|1|_vip5a60be577ad2b [1] => WAN_VSATGW|2|_vip5a4bc724a886d ) [trigger] => 0 [descr] => ) [1] => Array ( [name] => WAN_GROUP_PROD [item] => Array ( [0] => WAN_VSATGW|2|_vip5a4bc724a886d ) [trigger] => 1 [descr] => ) [2] => Array ( [name] => WAN_GROUP_EMER [item] => Array ( [0] => WAN_UMTSGW|1|address [1] => WAN_VSATGW|2|address ) [trigger] => 0 [descr] => ) )
CHECK
if (stristr($status['status'], "down")) { $msg = sprintf(gettext('MONITOR: %1$s is down, omitting from routing group %2$s'), $gwname, $group['name']); $gwdown = true; } else if (stristr($status['status'], "loss") && strstr($group['trigger'], "loss")) { /* packet loss */ $msg = sprintf(gettext('MONITOR: %1$s has packet loss, omitting from routing group %2$s'), $gwname, $group['name']); $gwdown = true; } else if (stristr($status['status'], "delay") && strstr($group['trigger'] , "latency")) { /* high latency */ $msg = sprintf(gettext('MONITOR: %1$s has high latency, omitting from routing group %2$s'), $gwname, $group['name']); $gwdown = true; }
Updated by Jim Thompson over 6 years ago
- Assignee set to Jim Pingle
- Priority changed from High to Normal
- Target version set to 2.4.4
Updated by Jim Pingle over 6 years ago
- Status changed from New to Feedback
- % Done changed from 0 to 100
Applied in changeset 9fa8c7de7bca843a3157807c66fecd3159b701ac.
Updated by Chris Macmahon over 6 years ago
2.4.4-DEVELOPMENT (amd64)
built on Fri Jul 06 15:23:49 EDT 2018
FreeBSD 11.2-RELEASE
2 gateways, setup a failover and a load balance groups.
Introduced packet loss/latency, on one of the wan links the other took over and worked as expected in a fail over setup.
Removed packet loss/latency on link and the link came back up.
Tested OK
Updated by Jim Pingle over 6 years ago
- Status changed from Feedback to Resolved
- Affected Version set to All
- Affected Architecture All added
- Affected Architecture deleted (
)