diff --git a/usr/local/www/carp_status.php b/usr/local/www/carp_status.php index 517697c7c4..25b31aa3fc 100644 --- a/usr/local/www/carp_status.php +++ b/usr/local/www/carp_status.php @@ -112,7 +112,13 @@ if($_POST['disablecarp'] <> "") { } } -$carp_detected_problems = ((get_single_sysctl("net.inet.carp.demotion")) > 0); +$carp_detected_problems = get_single_sysctl("net.inet.carp.demotion"); + +if (!empty($_POST['resetdemotion'])) { + set_single_sysctl("net.inet.carp.demotion", "-{$carp_detected_problems}"); + sleep(1); + $carp_detected_problems = get_single_sysctl("net.inet.carp.demotion"); +} $pgtitle = array(gettext("Status"),gettext("CARP")); $shortcut_section = "carp"; @@ -125,8 +131,21 @@ include("head.inc");