New to KubeDB? Please start here.
Restart Milvus
KubeDB supports restarting a Milvus database via a MilvusOpsRequest. Restarting can be useful to recover from a transient issue or to force pods to re-read mounted secrets/config.
Before You Begin
You should be familiar with the following
KubeDBconcepts:An object-storage secret named
my-release-miniomust exist in thedemonamespace.
Note: The yaml files used in this tutorial are stored in docs/guides/milvus/restart/yamls folder in GitHub repository kubedb/docs.
Restart Standalone Milvus
Deploy a standalone Milvus and wait until it is Ready (see the quickstart).
Apply the Restart OpsRequest
restart-standalone.yaml
apiVersion: ops.kubedb.com/v1alpha1
kind: MilvusOpsRequest
metadata:
name: restart
namespace: demo
spec:
type: Restart
databaseRef:
name: milvus-standalone
timeout: 5m
apply: Always
Here,
spec.type: Restartselects the restart operation.spec.databaseRef.nameis the database to restart.spec.apply: Alwaysapplies the restart regardless of the database’s current readiness.
$ kubectl apply -f https://github.com/kubedb/docs/raw/v2026.6.19/docs/guides/milvus/restart/yamls/restart-standalone.yaml
milvusopsrequest.ops.kubedb.com/restart created
Watch Progress
$ kubectl get milvusopsrequest restart -n demo
NAME TYPE STATUS AGE
restart Restart Successful 57s
$ kubectl describe milvusopsrequest restart -n demo
...
Status:
Conditions:
Message: Milvus ops-request has started to restart milvus nodes
Reason: Restart
Type: Restart
Message: get pod; ConditionStatus:True; PodName:milvus-standalone-0
Type: GetPod--milvus-standalone-0
Message: evict pod; ConditionStatus:True; PodName:milvus-standalone-0
Type: EvictPod--milvus-standalone-0
Message: check pod running; ConditionStatus:True; PodName:milvus-standalone-0
Type: CheckPodRunning--milvus-standalone-0
Message: Successfully Restarted Milvus nodes
Reason: RestartNodes
Type: RestartNodes
Message: Controller has successfully restart the Milvus replicas
Reason: Successful
Type: Successful
Phase: Successful
Events:
Normal Starting Pausing Milvus databse: demo/milvus-standalone
Warning evict pod; ConditionStatus:True; PodName:milvus-standalone-0
Warning check pod running; ConditionStatus:True; PodName:milvus-standalone-0
Normal RestartNodes Successfully Restarted Milvus nodes
Normal Successful Successfully resumed Milvus database: demo/milvus-standalone for MilvusOpsRequest: restart
The pod has been evicted and recreated:
$ kubectl get pods -n demo -l app.kubernetes.io/instance=milvus-standalone
NAME READY STATUS RESTARTS AGE
milvus-standalone-0 1/1 Running 0 14s
Restart Distributed Milvus
For a distributed Milvus, the same Restart OpsRequest is used, pointing at the distributed database (milvus-cluster). The operator restarts the pods of every distributed role (mixcoord, datanode, querynode, streamingnode, proxy) one workload at a time.
restart-distributed.yaml
apiVersion: ops.kubedb.com/v1alpha1
kind: MilvusOpsRequest
metadata:
name: restart
namespace: demo
spec:
type: Restart
databaseRef:
name: milvus-cluster
timeout: 5m
apply: Always
$ kubectl apply -f https://github.com/kubedb/docs/raw/v2026.6.19/docs/guides/milvus/restart/yamls/restart-distributed.yaml
milvusopsrequest.ops.kubedb.com/restart created
$ kubectl get milvusopsrequest restart -n demo
NAME TYPE STATUS AGE
restart Restart Successful 2m8s
The describe output shows each role’s pod being evicted and checked in turn:
$ kubectl describe milvusopsrequest restart -n demo
...
Status:
Conditions:
Message: Milvus ops-request has started to restart milvus nodes
Reason: Restart
Type: Restart
Message: evict pod; ConditionStatus:True; PodName:milvus-cluster-mixcoord-0
Type: EvictPod--milvus-cluster-mixcoord-0
Message: check pod running; ConditionStatus:True; PodName:milvus-cluster-mixcoord-0
Type: CheckPodRunning--milvus-cluster-mixcoord-0
Message: evict pod; ConditionStatus:True; PodName:milvus-cluster-datanode-0
Type: EvictPod--milvus-cluster-datanode-0
... (querynode, streamingnode, proxy follow)
Phase: Successful
All role pods have been recreated:
$ kubectl get pods -n demo -l app.kubernetes.io/instance=milvus-cluster
NAME READY STATUS RESTARTS AGE
milvus-cluster-datanode-0 1/1 Running 0 105s
milvus-cluster-mixcoord-0 1/1 Running 0 114s
milvus-cluster-proxy-0 1/1 Running 0 13s
milvus-cluster-querynode-0 1/1 Running 0 65s
milvus-cluster-streamingnode-0 1/1 Running 0 25s
Cleaning up
$ kubectl delete milvusopsrequest -n demo restart
$ kubectl delete milvus.kubedb.com -n demo milvus-standalone
$ kubectl delete ns demo
Next Steps
- Learn how to reconfigure a Milvus database.
- Detail concepts of Milvus object.
- Want to hack on KubeDB? Check our contribution guidelines.































