Skip to content

Commit

Permalink
Downgrade updates after testing
Browse files Browse the repository at this point in the history
  • Loading branch information
tmjd committed Dec 21, 2017
1 parent ac0e67d commit 48d6343
Showing 1 changed file with 53 additions and 23 deletions.
76 changes: 53 additions & 23 deletions master/getting-started/kubernetes/upgrade/downgrade.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,40 @@ title: Downgrading Calico
no_canonical: true
---

## About downgrading {{site.prodname}}

Under some circumstances, you may need to perform a downgrade and return your
cluster to the previous version of {{site.prodname}}. You may need to do this
before running `calico-upgrade complete` or afterwards. If you need to downgrade
your cluster after running `calico-upgrade complete`, you should do so as soon
as possible to avoid an outage. Any pods created after `calico-upgrade complete`
and before downgrading will lose networking.
cluster to the previous version of {{site.prodname}}. If you need to downgrade
you should do so as soon as possible to avoid an outage.

The downgrade procedure varies according to how you originally installed
{{site.prodname}} and your datastore type.

- [Downgrading a self-hosted installation that uses the etcd
datastore](#downgrading-a-self-hosted-installation-that-uses-theetcd-datastore)
is necessary when migration has been done and the {{site.prodname}}
components have been upgraded.
> **Important**: Any pods created after `calico-upgrade complete` and
> before downgrading will lose networking.
{: .alert .alert-danger}

- [Aborting the upgrade when using the etcd
datastore](#aborting-the-upgrade-when-using-the-etcd-datastore) can be done
when the migration has been started but the {{site.prodname}} components
have not been upgraded.

## Downgrading a self-hosted installation
- [Downgrading a self-hosted installation that uses the Kubernetes API
datastore](downgrading-a-self-hosted-installation-that-uses-the-kubernetes-api-datastore)

- [Downgrading a custom installation](downgrading-a-custom-installation)

## Downgrading a self-hosted installation that uses the etcd datastore

If you have upgraded {{site.prodname}} by deploying the latest manifest,
follow the steps here to downgrade.

1. Follow the steps in [Aborting the upgrade](#aborting-the-upgrade)
1. Follow the steps in
[Aborting the upgrade](#aborting-the-upgrade-that-uses-the-etcd-datastore)
before downgrading the {{site.prodname}} components.

1. Use the following commands to initiate a downgrade of the {{site.prodname}} components.
Expand All @@ -25,26 +46,15 @@ follow the steps here to downgrade.
kubectl rollout undo deployment/calico-kube-controllers -n kube-system
```

1. Watch the status of the downgrade as follows.
1. Watch the status of the downgrade as follows. When it reports complete and
successful, {{site.prodname}} is downgraded to the previous version.

```
watch kubectl get pods -n kube-system
kubectl rollout status deployment/calico-kube-controllers -n kube-system
kubectl rollout status ds/calico-node -n kube-system
```

Verify that the status of all {{site.prodname}} pods indicate `Running`.

```
calico-kube-controllers-6d4b9d6b5b-wlkfj 1/1 Running 0 3m
calico-node-hvvg8 2/2 Running 0 3m
calico-node-vm8kh 2/2 Running 0 3m
calico-node-w92wk 2/2 Running 0 3m
```

## Downgrading a custom installation

_Docs for this coming soon!_

## Aborting the upgrade
## Aborting the upgrade when using the etcd datastore

If you have not upgraded the {{site.prodname}} components then follow
the steps here to abort the upgrade and continue using your currently deployed
Expand All @@ -61,3 +71,23 @@ version of {{site.prodname}}.
> **Important**: Do not use versions of `calicoctl` v3.0+ after aborting the upgrade.
> Doing so may result in unexpected behavior and data.
{: .alert .alert-danger}

## Downgrading a self-hosted installation that uses the Kubernetes API datastore

1. Use the following commands to initiate a downgrade of the {{site.prodname}} components.

```
kubectl rollout undo ds/calico-node -n kube-system
```

1. Watch the status of the downgrade as follows. When it reports complete and
a successful, {{site.prodname}} is downgraded to the previous version.

```
kubectl rollout status ds/calico-node -n kube-system
```

## Downgrading a custom installation

_Docs for this coming soon!_

0 comments on commit 48d6343

Please sign in to comment.