Skip to main content

Primary / Secondary Cluster Mode Monitoring

Primary / Secondary Cluster Mode Monitoring

Primary / Secondary cluster mode monitoring ensures that only the primary cluster performs collections and interacts with external sources, while the secondary cluster remains passive. This prevents redundant traffic and reduces unnecessary load on devices, cloud services, and endpoints.

Prerequisites

  • Both clusters must be configured with S3-compatible storage.
  • Both clusters must point to the same S3 bucket.

How It Works

  • S3 bucket lock ownership determines which cluster is primary.
  • The cluster that owns the bucket lock is the primary cluster; the other becomes the secondary cluster.
  • If the primary cluster loses connectivity to S3 for more than 30 minutes, it automatically transitions to secondary mode until connectivity is restored.
  • If monitoring is enabled without S3 storage configured, the cluster immediately enters secondary mode.
  • Only the cluster in the primary role performs collections and interacts with external sources.

Enabling Monitoring

Enable monitoring on each cluster with the following API call:

PUT /api/deployment-config/CLUSTER_MODE_MONITORING?value=true

This API must be applied on both clusters in the pair.

Checking Cluster State

The cluster role (primary or secondary) can be verified with the following API call:

GET /api/cluster-mode

Failover Process

To manually fail over from a primary to a secondary cluster:

  1. (Optional) Take a backup on the current primary cluster.
  2. On the secondary cluster, follow the steps in Override Bucket Ownership in the S3-compatible storage to take control of the S3 bucket.
  3. Perform a restore from the latest backup on the new primary cluster to ensure consistent state.
warning

Skipping the restore step may result in inconsistent states between clusters.

note

Changes in cluster mode may take up to 5 minutes to propagate.