2022-01-21 10:05:58 +00:00
---
2023-10-02 12:50:08 +00:00
weight: 8
2023-01-11 15:38:18 +00:00
title: High Availability
2023-10-05 10:43:28 +00:00
menu:
docs:
parent: "operator"
weight: 8
2023-11-22 11:59:07 +00:00
aliases:
2024-08-16 14:32:25 +00:00
- /operator/high-availability/
- /operator/high-availability/index.html
2022-01-21 10:05:58 +00:00
---
2023-10-02 12:50:08 +00:00
High availability is not only important for customer-facing software but if the monitoring infrastructure is not highly available, then there is a risk that operations people are not notified of alerts.
Therefore, high availability must be just as thought through for the monitoring stack, as for anything else.
2022-01-21 10:05:58 +00:00
2023-10-02 12:50:08 +00:00
## Components
2022-01-21 10:05:58 +00:00
2023-10-02 12:50:08 +00:00
VictoriaMetrics operator support high availability for each component of the monitoring stack:
2022-01-21 10:05:58 +00:00
2024-08-16 14:32:25 +00:00
- [VMAgent ](https://docs.victoriametrics.com/operator/resources/vmagent/#high-availability )
- [VMAlert ](https://docs.victoriametrics.com/operator/resources/vmalert/#high-availability )
- [VMAlertmanager ](https://docs.victoriametrics.com/operator/resources/vmalertmanager/#high-availability )
- [VMAuth ](https://docs.victoriametrics.com/operator/resources/vmauth/#high-availability )
- [VMCluster ](https://docs.victoriametrics.com/operator/resources/vmcluster/#high-availability )
2022-01-21 10:05:58 +00:00
2024-08-16 14:32:25 +00:00
More details you can find in the section ** [High Availability for resources ](https://docs.victoriametrics.com/operator/resources/#high-availability )**.
2023-03-06 10:58:31 +00:00
2023-10-02 12:50:08 +00:00
## Operator
2023-03-06 10:58:31 +00:00
2023-10-02 12:50:08 +00:00
VictoriaMetrics operator can be safely scaled horizontally, but only one replica of the operator can
2024-08-16 14:32:25 +00:00
process [the reconciliation ](https://docs.victoriametrics.com/operator/#reconciliation-cycle ) at a time -
2023-10-02 12:50:08 +00:00
it uses a leader election mechanism to ensure that only one replica is active at a time.
2023-03-06 10:58:31 +00:00
2023-10-02 12:50:08 +00:00
If one of replicas of the operator will be failed, then another replica will be elected as a leader and will continue to work -
operator replication affects how quickly this happens.
2022-01-21 10:05:58 +00:00
2024-08-16 14:32:25 +00:00
[CRD validation ](https://docs.victoriametrics.com/operator/configuration#crd-validation ) workload is fully
2023-10-02 12:50:08 +00:00
distributed among the available operator replicas.
2022-01-21 10:05:58 +00:00
2023-10-02 12:50:08 +00:00
In addition, you can safely use for operator such features
as [assigning and distributing to nodes ](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/ )
(like [node selector ](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#nodeselector ),
[affinity and anti-affinity ](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#affinity-and-anti-affinity ),
[topology spread constraints ](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#pod-topology-spread-constraints ),
[taints and tolerations ](https://kubernetes.io/docs/concepts/scheduling-eviction/taint-and-toleration/ ), etc...)
2023-03-06 10:58:31 +00:00
2024-08-16 14:32:25 +00:00
In addition, don't forget about [monitoring for the operator ](https://docs.victoriametrics.com/operator/monitoring/ ).