Maintenance Mode
cnSGW-CSMF supports the maintenance mode flag to disable the impact on a cluster if the cluster in GR setup is scheduled for in-service (rolling upgrade). This is useful so that the other mated cluster executes its responsibility and other activities on the targeted cluster without any issue.
If the maintenance mode flag is set to true, cluster role change and GR trigger for the rack is allowed only in case of CLI-based failover.
During the execution, all the monitoring threads check the runtime value for the flag and hold the execution if the maintenance mode flag is set to true. By default, for fresh installation, the flag is set to false. Based on your requirements, to configure the maintenance mode, use the following configuration.
config
geo maintenance mode { true | false }
end
NOTES:
-
geo maintenance mode { true | false } - Enable/disable the maintenance mode.
The value for the maintenance mode is stored in.etcd
Both the clusters can be under maintenance at the same time. You can push the system in maintenance mode if the mated cluster is already under maintenance. Before you start the maintenance activity, set the geo maintenance mode
flag value to true. When maintenance is complete, reset the flag to false after confirming the health of the system.
When the maintenance flag is set to true:
-
All the monitoring activities are paused.
-
The mated cluster cannot trigger the failover when it detects the local failure.
-
Replication activities continue on the cluster.
-
Maintenance mode doesn't change instance roles of the site implicitly. However, role change is possible using
geo switch-role role
CLI command.
GR trigger is not allowed towards and from the cluster under maintenance. Only CLI-based failover is supported from the cluster under the maintenance. After disabling maintenance mode, start with new data for pod and VIP monitoring. Remote cluster is informed about the maintenance mode value using the NotifyMaintenanceActivity() [Operation 24] message.
Example
The following is a configuration example:
geo maintenance mode true
result "success"
geo maintenance mode false
result "success"
Viewing the Maintenance Mode Status
To check the maintenance mode status, use the following show
command.
show geo maintenance mode
result "geo maintenance mode is disabled"