From a0bf266f7fe54edfb088770fce54e14b004d1255 Mon Sep 17 00:00:00 2001 From: Ming Date: Thu, 20 Oct 2022 07:43:26 +0000 Subject: [PATCH] Add v1.10 velero upgrade doc Signed-off-by: Ming --- changelogs/unreleased/5468-qiuming-best | 1 + site/content/docs/main/upgrade-to-1.10.md | 91 ++++++++++++++++++++++ site/content/docs/main/upgrade-to-1.9.md | 94 ----------------------- 3 files changed, 92 insertions(+), 94 deletions(-) create mode 100644 changelogs/unreleased/5468-qiuming-best create mode 100644 site/content/docs/main/upgrade-to-1.10.md delete mode 100644 site/content/docs/main/upgrade-to-1.9.md diff --git a/changelogs/unreleased/5468-qiuming-best b/changelogs/unreleased/5468-qiuming-best new file mode 100644 index 000000000..96b49b4df --- /dev/null +++ b/changelogs/unreleased/5468-qiuming-best @@ -0,0 +1 @@ +Add v1.10 velero upgrade doc diff --git a/site/content/docs/main/upgrade-to-1.10.md b/site/content/docs/main/upgrade-to-1.10.md new file mode 100644 index 000000000..128f72801 --- /dev/null +++ b/site/content/docs/main/upgrade-to-1.10.md @@ -0,0 +1,91 @@ +--- +title: "Upgrading to Velero 1.10" +layout: docs +--- + +## Prerequisites + +- Velero [v1.9.x][5] installed. + +If you're not yet running at least Velero v1.6, see the following: + +- [Upgrading to v1.5][1] +- [Upgrading to v1.6][2] +- [Upgrading to v1.7][3] +- [Upgrading to v1.8][4] +- [Upgrading to v1.9][5] + +Before upgrading, check the [Velero compatibility matrix](https://github.com/vmware-tanzu/velero#velero-compatabilty-matrix) to make sure your version of Kubernetes is supported by the new version of Velero. + +## Instructions + +**Caution:** From Velero v1.10, except for using restic to do file-system level backup and restore, kopia is also been integrated, so there would be a little bit of difference when upgrading to v1.10 from a version lower than v1.10.0. + +1. Install the Velero v1.10 command-line interface (CLI) by following the [instructions here][0]. + + Verify that you've properly installed it by running: + + ```bash + velero version --client-only + ``` + + You should see the following output: + + ```bash + Client: + Version: v1.10.0 + Git commit: + ``` + +1. Update the Velero custom resource definitions (CRDs) to include schema changes across all CRDs that are at the core of the new features in this release: + + ```bash + velero install --crds-only --dry-run -o yaml | kubectl apply -f - + ``` + + **NOTE:** Since velero v1.10.0 only v1 CRD will be supported during installation, therefore, the v1.10.0 will only work on kubernetes version >= v1.16 + +1. Update the container image and objects fields used by the Velero deployment and, optionally, the restic daemon set: + + ```bash + # uploader_type value could be restic or kopia + kubectl get deploy -n velero -ojson \ + | sed "s#\"image\"\: \"velero\/velero\:v[0-9]*.[0-9]*.[0-9]\"#\"image\"\: \"velero\/velero\:main\"#g" \ + | sed "s#\"server\",#\"server\",\"--uploader-type=$uploader_type\",#g" \ + | sed "s#default-volumes-to-restic#default-volumes-to-fs-backup#g" \ + | sed "s#default-restic-prune-frequency#default-repo-maintain-frequency#g" \ + | sed "s#restic-timeout#fs-backup-timeout#g" \ + | kubectl apply -f - + + # optional, if using the restic daemon set + dsjson=$(kubectl get ds -n velero -ojson) + kubectl delete ds -n velero --all --force --grace-period 0 + echo $dsjson | sed "s#\"image\"\: \"velero\/velero\:v[0-9]*.[0-9]*.[0-9]\"#\"image\"\: \"velero\/velero\:v1.10.0\"#g" \ + | sed "s#\"name\"\: \"restic\"#\"name\"\: \"node-agent\"#g" \ + | sed "s#\[ \"restic\",#\[ \"node-agent\",#g" \ + | kubectl apply -f - + ``` + +1. Confirm that the deployment is up and running with the correct version by running: + + ```bash + velero version + ``` + + You should see the following output: + + ```bash + Client: + Version: v1.10.0 + Git commit: + + Server: + Version: v1.10.0 + ``` + +[0]: basic-install.md#install-the-cli +[1]: https://velero.io/docs/v1.5/upgrade-to-1.5 +[2]: https://velero.io/docs/v1.6/upgrade-to-1.6 +[3]: https://velero.io/docs/v1.7/upgrade-to-1.7 +[4]: https://velero.io/docs/v1.8/upgrade-to-1.8 +[5]: https://velero.io/docs/v1.9/upgrade-to-1.9 \ No newline at end of file diff --git a/site/content/docs/main/upgrade-to-1.9.md b/site/content/docs/main/upgrade-to-1.9.md deleted file mode 100644 index 25186dcd2..000000000 --- a/site/content/docs/main/upgrade-to-1.9.md +++ /dev/null @@ -1,94 +0,0 @@ ---- -title: "Upgrading to Velero 1.9" -layout: docs ---- - -## Prerequisites - -- Velero [v1.8.x][8] installed. - -If you're not yet running at least Velero v1.6, see the following: - -- [Upgrading to v1.1][1] -- [Upgrading to v1.2][2] -- [Upgrading to v1.3][3] -- [Upgrading to v1.4][4] -- [Upgrading to v1.5][5] -- [Upgrading to v1.6][6] -- [Upgrading to v1.7][7] -- [Upgrading to v1.8][8] - -Before upgrading, check the [Velero compatibility matrix](https://github.com/vmware-tanzu/velero#velero-compatabilty-matrix) to make sure your version of Kubernetes is supported by the new version of Velero. - -## Instructions - -1. Install the Velero v1.9 command-line interface (CLI) by following the [instructions here][0]. - - Verify that you've properly installed it by running: - - ```bash - velero version --client-only - ``` - - You should see the following output: - - ```bash - Client: - Version: v1.9.0 - Git commit: - ``` - -1. Update the Velero custom resource definitions (CRDs) to include schema changes across all CRDs that are at the core of the new features in this release: - - ```bash - velero install --crds-only --dry-run -o yaml | kubectl apply -f - - ``` - - **NOTE:** Since velero v1.9.0 only v1 CRD will be supported during installation, therefore, the v1.9.0 will only work on kubernetes version >= v1.16 - -1. Update the container image used by the Velero deployment and, optionally, the restic daemon set: - - ```bash - kubectl set image deployment/velero \ - velero=velero/velero:v1.9.0 \ - --namespace velero - - # optional, if using the restic daemon set - kubectl set image daemonset/restic \ - restic=velero/velero:v1.9.0 \ - --namespace velero - ``` - -1. Confirm that the deployment is up and running with the correct version by running: - - ```bash - velero version - ``` - - You should see the following output: - - ```bash - Client: - Version: v1.9.0 - Git commit: - - Server: - Version: v1.9.0 - ``` - -## Notes -### Default backup storage location -We have deprecated the way to indicate the default backup storage location. Previously, that was indicated according to the backup storage location name set on the velero server-side via the flag `velero server --default-backup-storage-location`. Now we configure the default backup storage location on the velero client-side. Please refer to the [About locations][9] on how to indicate which backup storage location is the default one. - -After upgrading, if there is a previously created backup storage location with the name that matches what was defined on the server side as the default, it will be automatically set as the `default`. - -[0]: basic-install.md#install-the-cli -[1]: https://velero.io/docs/v1.1.0/upgrade-to-1.1/ -[2]: https://velero.io/docs/v1.2.0/upgrade-to-1.2/ -[3]: https://velero.io/docs/v1.3.2/upgrade-to-1.3/ -[4]: https://velero.io/docs/v1.4/upgrade-to-1.4/ -[5]: https://velero.io/docs/v1.5/upgrade-to-1.5 -[6]: https://velero.io/docs/v1.6/upgrade-to-1.6 -[7]: https://velero.io/docs/v1.7/upgrade-to-1.7 -[8]: https://velero.io/docs/v1.8/upgrade-to-1.8 -[9]: https://velero.io/docs/v1.9/locations \ No newline at end of file