#!/usr/local/bin/php # $Id$ exec("stty status '^T'"); # Set shell to ignore SIGINT (2), but not children; # shell catches SIGQUIT (3) and returns to single user after fsck. exec("trap : 2"); exec("trap : 3"); require("guiconfig.inc"); /* bring down carp gracefully */ $carp_counter=find_number_of_created_carp_interfaces(); 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} destroy"); } exit 0;