diff options
author | glebius <glebius@FreeBSD.org> | 2011-12-20 13:53:31 +0000 |
---|---|---|
committer | glebius <glebius@FreeBSD.org> | 2011-12-20 13:53:31 +0000 |
commit | 8c74bad9f352ee33107ec1cbfa7273cb27d41a98 (patch) | |
tree | 5763c925081c47070f96599b2dbbbeee072455c2 /share | |
parent | 7cd583b49ab304c1a94bc8e9c2be06e7634dc2bf (diff) | |
download | FreeBSD-src-8c74bad9f352ee33107ec1cbfa7273cb27d41a98.zip FreeBSD-src-8c74bad9f352ee33107ec1cbfa7273cb27d41a98.tar.gz |
Restore a feature that was present in 5.x and 6.x, and was cleared in
7.x, 8.x and 9.x with pf(4) imports: pfsync(4) should suppress CARP
preemption, while it is running its bulk update.
However, reimplement the feature in more elegant manner, that is
partially inspired by newer OpenBSD:
- Rename term "suppression" to "demotion", to match with OpenBSD.
- Keep a global demotion factor, that can be raised by several
conditions, for now these are:
- interface goes down
- carp(4) has problems with ip_output() or ip6_output()
- pfsync performs bulk update
- Unlike in OpenBSD the demotion factor isn't a counter, but
is actual value added to advskew. The adjustment values for
particular error conditions are also configurable, and their
defaults are maximum advskew value, so a single failure bumps
demotion to maximum. This is for POLA compatibility, and should
satisfy most users.
- Demotion factor is a writable sysctl, so user can do
foot shooting, if he desires to.
Diffstat (limited to 'share')
-rw-r--r-- | share/man/man4/carp.4 | 39 |
1 files changed, 31 insertions, 8 deletions
diff --git a/share/man/man4/carp.4 b/share/man/man4/carp.4 index 7c214ff..1b59e72 100644 --- a/share/man/man4/carp.4 +++ b/share/man/man4/carp.4 @@ -26,7 +26,7 @@ .\" .\" $FreeBSD$ .\" -.Dd December 16, 2011 +.Dd December 20, 2011 .Dt CARP 4 .Os .Sh NAME @@ -121,15 +121,38 @@ Values above 1 enable logging of bad .Nm packets. Default value is 1. -.It Va net.inet.carp.suppress_preempt -A read only value showing the status of preemption suppression. -Preemption can be suppressed if link on an interface is down -or when +.It Va net.inet.carp.demotion +This value shows current level of CARP demotion. +The value is added to the actual advskew sent in announcements for +all vhids. +At normal system operation the demotion factor is zero. +However, problematic conditions raise its level: when +.Nm +experiences problem with sending announcements, when an interface +running a vhid goes down, or while the .Xr pfsync 4 interface is not synchronized. -Value of 0 means that preemption is not suppressed, since no -problems are detected. -Every problem increments suppression counter. +The demotion value is writable, so that user may alter it +depending on some external conditions, for example on status of some +daemon utility. +However, altering the value should be performed with care, do +not conflict with subsystems that adjust demotion factor +automatically: +.Nm +and +.Xr pfsync 4 . +.It Va net.inet.carp.ifdown_demotion_factor +Value added to +.Va net.inet.carp.demotion +when interface running a vhid goes down. +Default value is 240 (maximum advskew value). +.It Va net.inet.carp.senderr_demotion_factor +Value added to +.Va net.inet.carp.demotion +when +.Nm +experiences errors sending its announcements. +Default value is 240 (maximum advskew value). .El .\".Sh ARP level load balancing .\"The |