Skip to content

Commit 92f058c

Browse files
authored
Merge pull request #3262 from liyun95/preview
update 2.6.0 upgrade guide
2 parents 9d9d348 + 9be1bcb commit 92f058c

File tree

6 files changed

+180
-257
lines changed

6 files changed

+180
-257
lines changed

site/en/adminGuide/upgrade_milvus_cluster-helm.md

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -97,11 +97,8 @@ helm upgrade my-release zilliztech/milvus \
9797
Wait for the upgrade to complete:
9898

9999
```bash
100-
# Monitor the upgrade progress
101-
kubectl get pods -l app.kubernetes.io/name=milvus -w
102-
103100
# Verify all pods are ready
104-
kubectl get pods -l app.kubernetes.io/name=milvus
101+
kubectl get pods
105102
```
106103

107104
### Step 3: Upgrade to v{{var.milvus_release_version}}
@@ -123,7 +120,7 @@ Confirm your cluster is running the new version:
123120

124121
```bash
125122
# Check pod status
126-
kubectl get pods -l app.kubernetes.io/name=milvus
123+
kubectl get pods
127124

128125
# Verify Helm release
129126
helm list

site/en/adminGuide/upgrade_milvus_standalone-docker.md

Lines changed: 1 addition & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Due to security concerns, Milvus upgrades its MinIO to RELEASE.2023-03-20T20-16-
2222

2323
</div>
2424

25-
## Upgrade Milvus by changing its image
25+
## Upgrade process
2626

2727
In normal cases, you can upgrade Milvus as follows:
2828

@@ -42,52 +42,6 @@ In normal cases, you can upgrade Milvus as follows:
4242
docker compose up -d
4343
```
4444

45-
## Migrate the metadata
46-
47-
1. Stop all Milvus components.
48-
49-
```
50-
docker stop <milvus-component-docker-container-name>
51-
```
52-
53-
2. Prepare the configuration file `migration.yaml` for meta migration.
54-
55-
```yaml
56-
# migration.yaml
57-
cmd:
58-
# Option: run/backup/rollback
59-
type: run
60-
runWithBackup: true
61-
config:
62-
sourceVersion: 2.1.4 # Specify your milvus version
63-
targetVersion: {{var.milvus_release_version}}
64-
backupFilePath: /tmp/migration.bak
65-
metastore:
66-
type: etcd
67-
etcd:
68-
endpoints:
69-
- milvus-etcd:2379 # Use the etcd container name
70-
rootPath: by-dev # The root path where data is stored in etcd
71-
metaSubPath: meta
72-
kvSubPath: kv
73-
```
74-
75-
3. Run the migration container.
76-
77-
```
78-
# Suppose your docker-compose run with the default milvus network,
79-
# and you put migration.yaml in the same directory with docker-compose.yaml.
80-
docker run --rm -it --network milvus -v $(pwd)/migration.yaml:/milvus/configs/migration.yaml milvusdb/meta-migration:v2.2.0 /milvus/bin/meta-migration -config=/milvus/configs/migration.yaml
81-
```
82-
83-
4. Start Milvus components again with the new Milvus image.
84-
85-
```shell
86-
// Run the following only after update the milvus image tag in the docker-compose.yaml
87-
docker compose down
88-
docker compose up -d
89-
```
90-
9145
## What's next
9246
- You might also want to learn how to:
9347
- [Scale a Milvus cluster](scaleout.md)

site/en/adminGuide/upgrade_milvus_standalone-helm.md

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@ Upgrading from Milvus 2.5.x to {{var.milvus_release_version}} involves significa
2424
- **New components**: Introduction of Streaming Node and other new components
2525
- **Component optimizations**: Enhanced performance and streamlined architecture
2626

27+
This upgrade process ensures proper migration to the new architecture. For more information on architecture changes, refer to <a href="architecture_overview.md">Milvus Architecture Overview</a>.
28+
2729
<div class="alert note">
28-
This upgrade is <strong>irreversible</strong>. You cannot roll back to a previous version once the upgrade is completed. For details on architectural changes, refer to <a href="architecture_overview.md">Milvus Architecture Overview</a>.
30+
This upgrade is <strong>irreversible</strong>. You cannot roll back to a previous version once the upgrade is completed.
2931
</div>
3032

3133
### Requirements
@@ -61,10 +63,16 @@ The Milvus Helm Charts repo at <code>https://milvus-io.github.io/milvus-helm/</c
6163

6264
### Step 2: Upgrade to v2.5.16
6365

66+
<div class="alert-note">
67+
68+
Skip this step if your standalone deployment is already running v2.5.16 or higher.
69+
70+
</div>
71+
6472
Upgrade your Milvus standalone to v2.5.16:
6573

6674
```bash
67-
helm upgrade my-release milvus/milvus \
75+
helm upgrade my-release zilliztech/milvus \
6876
--set image.all.tag="v2.5.16" \
6977
--reset-then-reuse-values \
7078
--version={{var.milvus_helm_chart_version}}
@@ -73,9 +81,6 @@ helm upgrade my-release milvus/milvus \
7381
Wait for the upgrade to complete:
7482

7583
```bash
76-
# Monitor the upgrade progress
77-
kubectl get pods -w
78-
7984
# Verify all pods are ready
8085
kubectl get pods
8186
```
@@ -85,7 +90,7 @@ kubectl get pods
8590
Once v2.5.16 is running successfully, upgrade to v{{var.milvus_release_version}}:
8691

8792
```bash
88-
helm upgrade my-release milvus/milvus \
93+
helm upgrade my-release zilliztech/milvus \
8994
--set image.all.tag="v{{var.milvus_release_tag}}" \
9095
--reset-then-reuse-values \
9196
--version={{var.milvus_helm_chart_version}}
@@ -97,10 +102,7 @@ Confirm your standalone deployment is running the new version:
97102

98103
```bash
99104
# Check pod status
100-
kubectl get pods -l app.kubernetes.io/name=milvus
101-
102-
# Verify Helm release
103-
helm list
105+
kubectl get pods
104106
```
105107

106108
For additional support, consult the [Milvus documentation](https://milvus.io/docs) or [community forum](https://github.com/milvus-io/milvus/discussions).

site/en/adminGuide/upgrade_milvus_standalone-operator.md

Lines changed: 62 additions & 106 deletions
Original file line numberDiff line numberDiff line change
@@ -12,160 +12,116 @@ title: Upgrade Milvus Standalone with Milvus Operator
1212

1313
# Upgrade Milvus Standalone with Milvus Operator
1414

15-
This guide describes how to upgrade your Milvus standalone with Milvus operator.
15+
This guide describes how to upgrade your Milvus standalone deployment from v2.5.x to v{{var.milvus_release_version}} using Milvus Operator.
1616

17-
## Upgrade your Milvus operator
17+
## Before you start
1818

19-
Run the following command to upgrade the version of your Milvus operator to v{{var.milvus_operator_version}}.
20-
21-
```
22-
helm repo add zilliztech-milvus-operator https://zilliztech.github.io/milvus-operator/
23-
helm repo update zilliztech-milvus-operator
24-
helm -n milvus-operator upgrade milvus-operator zilliztech-milvus-operator/milvus-operator
25-
```
26-
27-
Once you have upgraded your Milvus operator to the latest version, you have the following choices:
19+
### What's new in v{{var.milvus_release_version}}
2820

21+
Upgrading from Milvus 2.5.x to {{var.milvus_release_version}} involves significant architectural changes:
2922

30-
- To upgrade Milvus from v2.2.3, you can [conduct a rolling upgrade](#Conduct-a-rolling-upgrade).
31-
- To upgrade Milvus from a minor release before v2.2.3 to {{var.milvus_release_version}}, you are advised to [upgrade Milvus by changing its image version](#Upgrade-Milvus-by-changing-its-image).
32-
- To upgrade Milvus from v2.1.x to {{var.milvus_release_version}}, you need to [migrate the metadata](#Migrate-the-metadata) before the actual upgrade.
23+
- **New components**: Introduction of Streaming Node and other new components
24+
- **Component optimizations**: Enhanced performance and streamlined architecture for standalone deployments
3325

34-
> **Note**: It's highly recommended to upgrade one minor version at a time, and to use the latest stable release of that minor version. For example, if you are upgrading from v2.4.x to v2.6.x, you should first upgrade to the latest v2.4.x, then to the latest v2.5.x, and finally to v2.6.x. This ensures that you are using the latest stable release of each minor version, which is more likely to be compatible with your existing data and configurations.
26+
This upgrade process ensures proper migration to the new architecture. For more information on architecture changes, refer to <a href="architecture_overview.md">Milvus Architecture Overview</a>.
3527

36-
## Conduct a rolling upgrade
28+
<div class="alert note">
29+
This upgrade is <strong>irreversible</strong>. You cannot roll back to a previous version once the upgrade is completed.
30+
</div>
3731

38-
Since Milvus 2.2.3, you can configure Milvus coordinators to work in active-standby mode and enable the rolling upgrade feature for them, so that Milvus can respond to incoming requests during the coordinator upgrades. In previous releases, coordinators are to be removed and then created during an upgrade, which may introduce certain downtime of the service.
32+
### Requirements
3933

40-
Based on the rolling update capabilities provided by Kubernetes, the Milvus operator enforces an ordered update of the deployments according to their dependencies. In addition, Milvus implements a mechanism to ensure that its components remain compatible with those depending on them during the upgrade, significantly reducing potential service downtime.
34+
**System requirements:**
35+
- Kubernetes cluster with Milvus standalone deployed via Milvus Operator
36+
- `kubectl` configured to access your cluster
37+
- Helm 3.x installed
4138

42-
The rolling upgrade feature is disabled by default. You need to explicitly enable it through a configuration file.
39+
**Compatibility requirements:**
40+
- Milvus v2.6.0-rc1 is **not compatible** with v{{var.milvus_release_version}}. Direct upgrades from release candidates are not supported.
41+
- You **must** upgrade to v2.5.16 before upgrading to v{{var.milvus_release_version}}.
4342

44-
```yaml
45-
apiVersion: milvus.io/v1beta1
46-
kind: Milvus
47-
metadata:
48-
name: my-release
49-
spec:
50-
components:
51-
enableRollingUpdate: true
52-
imageUpdateMode: rollingUpgrade # Default value, can be omitted
53-
image: milvusdb/milvus:v{{var.milvus_release_tag}}
54-
```
43+
## Upgrade process
5544

56-
In this above configuration file, set `spec.components.enableRollingUpdate` to `true` and set `spec.components.image` to the desired Milvus version.
45+
### Step 1: Upgrade Milvus Operator
5746

58-
By default, Milvus performs a rolling upgrade for coordinators in an ordered way, in which it replaces the coordinator pod images one after another. To reduce the upgrade time, consider setting `spec.components.imageUpdateMode` to `all` so that Milvus replaces all pod images at the same time.
47+
First, upgrade your Milvus Operator to v{{var.milvus_operator_version}}:
5948

60-
```yaml
61-
apiVersion: milvus.io/v1beta1
62-
kind: Milvus
63-
metadata:
64-
name: my-release
65-
spec:
66-
components:
67-
enableRollingUpdate: true
68-
imageUpdateMode: all
69-
image: milvusdb/milvus:v{{var.milvus_release_tag}}
49+
```bash
50+
helm repo add zilliztech-milvus-operator https://zilliztech.github.io/milvus-operator/
51+
helm repo update zilliztech-milvus-operator
52+
helm -n milvus-operator upgrade milvus-operator zilliztech-milvus-operator/milvus-operator
7053
```
7154

72-
You can set `spec.components.imageUpdateMode` to `rollingDowngrade` to have Milvus replace coordinator pod images with a lower version.
55+
Verify the operator upgrade:
7356

74-
```yaml
75-
apiVersion: milvus.io/v1beta1
76-
kind: Milvus
77-
metadata:
78-
name: my-release
79-
spec:
80-
components:
81-
enableRollingUpdate: true
82-
imageUpdateMode: rollingDowngrade
83-
image: milvusdb/milvus:<some-older-version>
57+
```bash
58+
kubectl -n milvus-operator get pods
8459
```
8560

86-
Then save your configuration as a YAML file (for example, `milvusupgrade.yaml`) and patch this configuration file to your Milvus instance as follows:
61+
### Step 2: Upgrade your Milvus standalone
8762

88-
```shell
89-
kubectl patch -f milvusupgrade.yaml --patch-file milvusupgrade.yaml --type merge
90-
```
63+
#### 2.1 Upgrade to v2.5.16
64+
65+
<div class="alert-note">
9166

92-
## Upgrade Milvus by changing its image
67+
Skip this step if your standalone deployment is already running v2.5.16 or higher.
9368

94-
In normal cases, you can simply update your Milvus to the latest by changing its image. However, note that there will be a certain downtime when upgrading Milvus in this way.
69+
</div>
9570

96-
Compose a configuration file as follows and save it as **milvusupgrade.yaml**:
71+
Create a configuration file `milvusupgrade.yaml` to upgrade to v2.5.16:
9772

9873
```yaml
9974
apiVersion: milvus.io/v1beta1
10075
kind: Milvus
10176
metadata:
102-
name: my-release
103-
labels:
104-
app: milvus
77+
name: my-release # Replace with your actual release name
10578
spec:
106-
# Omit other fields ...
10779
components:
108-
image: milvusdb/milvus:v{{var.milvus_release_tag}}
80+
image: milvusdb/milvus:v2.5.16
10981
```
11082
111-
Then run the following to perform the upgrade:
83+
Apply the configuration:
11284
113-
```shell
85+
```bash
11486
kubectl patch -f milvusupgrade.yaml --patch-file milvusupgrade.yaml --type merge
11587
```
11688

117-
## Migrate the metadata
89+
Wait for completion:
11890

119-
Since Milvus 2.2.0, the metadata is incompatible with that in previous releases. The following example snippets assume an upgrade from Milvus 2.1.4 to Milvus v{{var.milvus_release_version}}.
91+
```bash
92+
# Verify all pods are ready
93+
kubectl get pods
94+
```
12095

121-
### 1. Create a `.yaml` file for metadata migration
96+
#### 2.2 Upgrade to v{{var.milvus_release_version}}
12297

123-
Create a metadata migration file. The following is an example. You need to specify the `name`, `sourceVersion`, and `targetVersion` in the configuration file. The following example sets the `name` to `my-release-upgrade`, `sourceVersion` to `v2.1.4`, and `targetVersion` to `v{{var.milvus_release_version}}`. This means that your Milvus instance will be upgraded from v2.1.4 to v{{var.milvus_release_version}}.
98+
Once v2.5.16 is running successfully, upgrade to v{{var.milvus_release_version}}:
12499

125-
```
100+
Update your configuration file (`milvusupgrade.yaml` in this example):
101+
102+
```yaml
126103
apiVersion: milvus.io/v1beta1
127-
kind: MilvusUpgrade
104+
kind: Milvus
128105
metadata:
129-
name: my-release-upgrade
106+
name: my-release # Replace with your actual release name
130107
spec:
131-
milvus:
132-
namespace: default
133-
name: my-release
134-
sourceVersion: "v2.1.4"
135-
targetVersion: "v{{var.milvus_release_version}}"
136-
# below are some omit default values:
137-
# targetImage: "milvusdb/milvus:v{{var.milvus_release_tag}}"
138-
# toolImage: "milvusdb/meta-migration:v2.2.0"
139-
# operation: upgrade
140-
# rollbackIfFailed: true
141-
# backupPVC: ""
142-
# maxRetry: 3
108+
components:
109+
image: milvusdb/milvus:v{{var.milvus_release_tag}}
143110
```
144111
145-
### 2. Apply the new configuration
146-
147-
Run the following command to apply the new configuration.
112+
Apply the final upgrade:
148113
114+
```bash
115+
kubectl patch -f milvusupgrade.yaml --patch-file milvusupgrade.yaml --type merge
149116
```
150-
$ kubectl create -f https://raw.githubusercontent.com/zilliztech/milvus-operator/main/config/samples/milvusupgrade.yaml
151-
```
152-
153-
154117

155-
### 3. Check the status of metadata migration
118+
## Verify the upgrade
156119

157-
Run the following command to check the status of your metadata migration.
120+
Confirm your standalone deployment is running the new version:
158121

122+
```bash
123+
# Check pod status
124+
kubectl get pods
159125
```
160-
kubectl describe milvus release-name
161-
```
162-
163-
The status of `ready` in the output means that the metadata migration is successful.
164-
165-
Or, you can also run `kubectl get pod` to check all the pods. If all the pods are `ready`, the metadata migration is successful.
166-
167-
168-
169-
### 4. Delete `my-release-upgrade`
170126

171-
When the upgrade is successful, delete `my-release-upgrade` in the YAML file.
127+
For additional support, consult the <a href="https://milvus.io/docs">Milvus documentation</a> or <a href="https://github.com/milvus-io/milvus/discussions">community forum</a>.

0 commit comments

Comments
 (0)