Project

General

Profile

Bug #10546

Gateways removed from routing groups based on low alert thresholds

Added by Vladimir Voskoboynikov 6 months ago. Updated 15 days ago.

Status:
Resolved
Priority:
Normal
Category:
Multi-WAN
Target version:
Start date:
05/10/2020
Due date:
% Done:

100%

Estimated time:
Affected Version:
2.4.5
Affected Architecture:
All

Description

In a Multi-WAN failover scenario, individual gateways are added and removed from gateway groups based on dpinger alarms, which trigger when the 'high' latency or packet loss thresholds are crossed. Gateways are added/removed from gateway groups in get_gwgroup_members_inner(), and the gateway status is reported from return_gateways_status() without a detailed status. Thus, the gateway status can be one of "down" (high latency or loss threshold exceeded), "loss" (low loss threshold exceeded), "delay" (low delay threshold exceeded), or "none" (below all thresholds).

get_gwgroup_members_inner() will also remove gateways for the "loss" and "delay" states, which is unexpected. This leaves the following potential scenario:

  1. A gateway exceeds the high latency (or loss) threshold. A dpinger alarm is raised, and the gateway is removed from the gateway group.
  2. The gateway returns to a latency between the low and high thresholds. A dpinger alarm is raised, but the gateway is not added back to the gateway group as it is still in a "loss" status.
  3. The gateway returns below the low loss threshold, and remains that way. No dpinger alarm is raised, as the high threshold was not crossed, and no code is ever called to reconsider the gateway groups. The gateway remains removed from the gateway group indefinitely.

In this case, pfsense will consider a gateway down when it has actually returned to a normal state, necessitating administrator action to return it back to a proper state.

Associated revisions

Revision 04a72a97 (diff)
Added by Vladimir Voskoboynikov 17 days ago

Add gateway substatus. Fixes #10546

Update return_gateways_status to return a substatus as well as the existing status.

status changed to be one of online or down.
substatus can be one of none, down, highloss, highlatency, loss, latency, or force_down

Edit status pages, gateway widget, and gateway group code accordingly.

Revision 094db492 (diff)
Added by Vladimir Voskoboynikov 17 days ago

Minor text fix. Issue #10546

No need to log the PID, it's added to the logs anyways.

History

#1 Updated by Jim Pingle 6 months ago

  • Target version set to 2.5.0

#2 Updated by Jim Pingle 5 months ago

  • Status changed from New to Pull Request Review

#3 Updated by Renato Botelho about 2 months ago

  • Assignee set to Renato Botelho

#4 Updated by Jörn Greszki about 1 month ago

Dear gents

is the behavior I describe

https://forum.netgate.com/topic/156890/dpinger-broken-or-dashboard-broken-or-my-brain-is-broken

related to your findings?

#5 Updated by Renato Botelho 17 days ago

  • Status changed from Pull Request Review to Feedback

PR has been merged. Thanks!

#6 Updated by Vladimir Voskoboynikov 17 days ago

  • % Done changed from 0 to 100

#7 Updated by Steve Beaver 15 days ago

  • Status changed from Feedback to Resolved

Also available in: Atom PDF