Resume or suspend a cluster
This topic describes how to resume or suspend a CelerData cluster.
The following examples assume that the cluster you want to resume or suspend is an elastic cluster, and the ellipses (...) in the following examples refer to the other existing arguments you have specified in the celerdatabyoc_elastic_cluster_v2 resource.
Example Usage - Resume Cluster
-
Set the
expected_cluster_stateargument toRunningin the Terraform configuration, as shown below:resource "celerdatabyoc_elastic_cluster_v2" "elastic_cluster" {
...
expected_cluster_state = "Running"
} -
(Optional) Check whether your project has been configured. If there are any errors, edit the configuration and re-run the following command:
terraform plan -
Apply the configuration:
terraform applyWhen the system returns "Apply complete!", the cluster is successfully resumed.
Example Usage - Suspend Cluster
-
Set the
expected_cluster_stateargument toSuspendedin the Terraform configuration, as shown below:resource "celerdatabyoc_elatic_cluster_v2" "elastic_cluster" {
...
expected_cluster_state = "Suspended"
} -
(Optional) Check whether your project has been configured. If there are any errors, edit the configuration and re-run the following command:
terraform plan -
Apply the configuration:
terraform applyWhen the system returns "Apply complete!", the cluster is suspended.
Argument Reference
The argument is described as follows:
expected_cluster_state: The status of the CelerData cluster. To resume a cluster, set the argument toRunning. To suspend a cluster, set the argument toSuspended.