diff --git a/Anvil/Tools/Cluster.pm b/Anvil/Tools/Cluster.pm index 120d31aa..834391ac 100644 --- a/Anvil/Tools/Cluster.pm +++ b/Anvil/Tools/Cluster.pm @@ -19,6 +19,7 @@ my $THIS_FILE = "Cluster.pm"; # assemble_storage_groups # boot_server # check_node_status +# check_server_constraints # check_stonith_config # delete_server # get_fence_methods @@ -750,6 +751,29 @@ sub check_node_status } +=head2 check_server_constraints + +This method checks to see if the peer node is offline, and the local node is only. If this is the case, the location constraints for servers are checked to ensure that they favour the current host. If not, the location constraint is updated. + +This is meant to be used to prevent servers from automatically migrating back to a node after it was fenced. + +This method takes no parameters. + +=cut +sub check_server_constraints +{ + my $self = shift; + my $parameter = shift; + my $anvil = $self->parent; + my $debug = defined $parameter->{debug} ? $parameter->{debug} : 3; + $anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => $debug, key => "log_0125", variables => { method => "Cluster->check_server_constraints()" }}); + + + + return(0); +} + + =head2 check_stonith_config This loads the running CIB and compares the fence (stonith) configuration against the records in the database. If a method needs to be updated, added or removed, this method will make those changes. As such, this method must be called on an active Anvil! node in order to work. diff --git a/tools/anvil-configure-host b/tools/anvil-configure-host index 9ee27a91..fb6c4499 100755 --- a/tools/anvil-configure-host +++ b/tools/anvil-configure-host @@ -678,7 +678,7 @@ sub reconfigure_network $link1_config .= "IPV6INIT=\"no\"\n"; $link1_config .= "ONBOOT=\"yes\"\n"; $link1_config .= "USERCTL=\"no\"\n"; - $link1_config .= "MTU=\"1500\"\n"; # TODO: Make the MTU user-adjustable +# $link1_config .= "MTU=\"1500\"\n"; # TODO: Make the MTU user-adjustable $link1_config .= "NM_CONTROLLED=\"yes\"\n"; $link1_config .= "SLAVE=\"yes\"\n"; $link1_config .= "MASTER=\"".$say_interface."_bond1\"\n"; @@ -694,7 +694,7 @@ sub reconfigure_network $link2_config .= "IPV6INIT=\"no\"\n"; $link2_config .= "ONBOOT=\"yes\"\n"; $link2_config .= "USERCTL=\"no\"\n"; - $link2_config .= "MTU=\"1500\"\n"; # TODO: Make the MTU user-adjustable +# $link2_config .= "MTU=\"1500\"\n"; # TODO: Make the MTU user-adjustable $link2_config .= "NM_CONTROLLED=\"yes\"\n"; $link2_config .= "SLAVE=\"yes\"\n"; $link2_config .= "MASTER=\"".$say_interface."_bond1\"\n"; @@ -1117,7 +1117,7 @@ sub reconfigure_network } $link1_config .= "DEFROUTE=\"".$say_defroute."\"\n"; $link1_config .= "USERCTL=\"no\"\n"; - $link1_config .= "MTU=\"1500\"\n"; # TODO: Make the MTU user-adjustable +# $link1_config .= "MTU=\"1500\"\n"; # TODO: Make the MTU user-adjustable $link1_config .= "NM_CONTROLLED=\"yes\"\n"; $link1_config .= "ZONE=\"".uc($say_interface)."\"";