v1.0
- About MogDB Stack
- Quick Start
- Installation
- Tutorial
- Architecture
- References
- Client
- Server
- FAQ
- Release Note
Resize a MogDB Cluster
Creating a Highly Available MogDB Cluster
High availability is enabled by default in MogDB Operator as long as you have multiple replicas. To create a High Availability MogDB cluster, you can execute the following command.
mgo create cluster cluster1 --replica=1
Scaling Up MogDB Cluster
You can use the following command mgo scale to scale an existing MogDB cluster to add slave nodes to it.
mgo scale cluster1
Scaling Down MogDB Cluster
To scaled down a MogDB cluster, you must provide the target of the instances to be scaled down. You can perform this operation using the following mgo scaledown command to perform this operation.
mgo scaledown cluster1 --query
Expected output:
PODNAME STATUS NODE
cluster1-rtwdz Running mogdb-k8s-002
After determining the instances to be scaled down, you can run the following command:
mgo scaledown cluster1 --target=cluster1-rtwdz