Deploy production-grade MongoDB clusters in minutes. ReplicaSet HA, sharding, backup & restore, and full Day-2 operations — all via a unified Kubernetes API.
RPO (w:majority)
Failover RTO
Open Source
Deploy MongoDB in 3 steps
Install KubeBlocks
# Add Helm repo helm repo add kubeblocks https://apecloud.github.io/helm-charts helm repo update # Install KubeBlocks helm install kubeblocks kubeblocks/kubeblocks \ --namespace kb-system --create-namespace
Create a ReplicaSet Cluster
apiVersion: apps.kubeblocks.io/v1 kind: Cluster metadata: name: mongodb-cluster namespace: demo spec: terminationPolicy: Delete clusterDef: mongodb topology: replicaset componentSpecs: - name: mongodb replicas: 3
Cluster is Ready
kubectl get cluster mongodb-cluster -n demo NAME CLUSTER-DEFINITION STATUS AGE mongodb-cluster mongodb Running 2m
Trusted by Engineering Teams at Scale
From a 3-node ReplicaSet to a sharded cluster — choose the topology that fits your workload.
One primary handles all writes while one or more secondaries replicate via the oplog. On primary failure, the remaining nodes hold an election — the member with the most up-to-date oplog and a majority of votes is promoted. Failover typically completes within 10–30 seconds.
Majority-vote election — no external coordinator required
Automatic promotion of the most up-to-date secondary
Read scale-out via secondary endpoints
Writes route via a role-aware ClusterIP service
w:majority write concern for stronger durability of acknowledged writes
mongo-cluster-mongodb-mongodb:27017mongo-cluster-mongodb-mongodb-ro:27017kubeblocks.io/role=primarykubeblocks.io/role=secondary| Feature | KubeBlocks | Percona Operator | MongoDB Community Operator |
|---|---|---|---|
| Open Source | ✓ | ✓ | ✓ |
| ReplicaSet HA | ✓ | ✓ | ✓ |
| Sharding | ✓ | ✓ | ✓ |
| TLS encryption | ✓ | ✓ | ✓ |
| TLS rotation | ✓ | ✓ | ~ |
| Backup (physical) | ✓ | ✓ | ✗ |
| Scheduled backup | ✓ | ✓ | ✗ |
| Restore from backup | ✓ | ✓ | ✗ |
| PITR (oplog streaming) | ✓ | ✓ | ✗ |
| Horizontal scaling | ✓ | ✓ | ✓ |
| Vertical scaling | ✓ | ✓ | ✓ |
| Volume expansion | ✓ | ✓ | ✓ |
| Dynamic config | ✓ | ✓ | ~ |
| Prometheus metrics | ✓ | ✓ | ✗ |
| Minor Upgrade | ✓ | ✓ | ~ |
| Major Upgrade | Enterprise Via blue-green deployment | ~ | ✗ |
| Cross-cluster DR (standby) | Enterprise | ✗ | ✗ |
| Bootstrap from external MongoDB | Enterprise | ✗ | ✗ |
| User & role management | Enterprise | ✓ | ✓ |
| Web management UI | Enterprise | ✗ | ✗ |
✓ = Supported · ~ = Partial / Limited · ✗ = Not supported
Enterpriseindicates a capability available in KubeBlocks Enterprise, not the open-source distribution. Contact us for licensing →
Based on publicly available documentation. Features may vary by version.
Backup, failover, scaling, and configuration — describe the desired state in YAML; KubeBlocks reconciles MongoDB for your chosen topology.
No SSH into pods, no shell scripts. Submit an OpsRequest and KubeBlocks handles the rest.
High Availability & Scaling
Horizontal Scaling
Add or remove replica set members online — KubeBlocks handles topology reconfiguration automatically.
Vertical Scaling
Resize CPU and memory on running instances with a rolling strategy.
Volume Expansion
Expand PVC storage without pod restarts on supported storage classes.
Rolling Restart
Controlled pod restarts with minimal disruption to active connections.
Planned Primary Stepdown
Trigger a graceful rs.stepDown() on demand to promote a specific secondary.
Stop / Start
Suspend clusters to eliminate compute cost; resume with full state restored.
Configuration, Security & Observability
Dynamic Configuration
Tune mongod parameters via OpsRequest — changes applied without restart where supported.
TLS Encryption
Enable, rotate, or disable in-flight encryption without downtime.
Custom Users & Roles
Declarative user and role management via Kubernetes Secrets — synced across all replica set members.
Password Management
Rotate credentials stored in Kubernetes Secrets with automatic propagation.
Version Upgrade
Rolling upgrades across MongoDB minor versions; major version upgrades with blue-green deployment are available in KubeBlocks Enterprise.
Prometheus Metrics
Per-instance metrics via mongodb-exporter, with pre-built Grafana dashboards.
Open source and production-ready. Enterprise customers get dedicated onboarding, migration support, and SLA-backed support.