Stops the logical cluster on one or more instances or the entire logical cluster, and places the instances or the cluster in the inactive state.
sp_cluster logical, "deactivate", lc_name, { "cluster" | "instance", instance_list } [, wait_option[, timeout,[, @handle output ]]]
lc_name – is the name of a logical cluster.
cluster – specifies the entire cluster.
instance – specifies that only certain instances in the logical cluster are to be placed in the inactive state.
instance_list – is a list of selected instances in the logical cluster.
wait_option – is how the time of the action is to be specified. Values are:
wait – indicates that existing connections are given a specified amount of time (or an infinite amount of time if no timeout is given) to migrate or disconnect.
nowait – indicates that existing connections are migrated or disconnected immediately.
until – indicates that existing connections are given until a specific time of day to migrate or disconnect.
timeout – is a specific amount of time (when used with wait) or a specific time (when used with until). The format is “hh:mm:ss” according to a 24-hour clock. For example, timeout records 11:30 p.m. as 23:30:00.
@handle output – specifies that an action handle is to be retrieved for the action.
Example 1 Immediately stops all instances in the “SalesLC” logical cluster, and places “SalesLC” in the inactive state.
sp_cluster logical, "deactivate", SalesLC, cluster, nowait
Example 2 Stops the “ase1” and “ase2” instances, and places “SalesLC” in the inactive state.
sp_cluster logical, "deactivate", SalesLC, instance, "ase1;ase2"
You cannot use the deactivate command for the system logical cluster.
offline is identical to the deactivate, except deactivate places stopped instances or clusters in the inactive state and offline places them in the offline state.