aboutsummaryrefslogtreecommitdiffstats
path: root/packages/carp_status.php
diff options
context:
space:
mode:
Diffstat (limited to 'packages/carp_status.php')
-rw-r--r--packages/carp_status.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/packages/carp_status.php b/packages/carp_status.php
index 2bcb7efa..c76ba0fa 100644
--- a/packages/carp_status.php
+++ b/packages/carp_status.php
@@ -40,9 +40,11 @@ if($_POST['disablecarp'] <> "") {
if($status == true) {
$savemsg = "{$carp_counter} ip's have been disabled.";
$carp_counter=find_number_of_created_carp_interfaces();
- for($x=0; $x<$carp_counter; $x++)
- mwexec("/sbin/ifconfig carp{$x} delete");
mwexec("/sbin/sysctl net.inet.carp.allow=0");
+ for($x=0; $x<$carp_counter; $x++) {
+ mwexec("/sbin/ifconfig carp{$x} down");
+ mwexec("/sbin/ifconfig carp{$x} delete");
+ }
} else {
$savemsg = "Carp has been enabled.";
mwexec("/sbin/sysctl net.inet.carp.allow=1");