> ## Documentation Index
> Fetch the complete documentation index at: https://docs.streamnative.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Upgrade the Pulsar Operators

If you install the Pulsar Operators using the Helm chart, you need to manually upgrade the Pulsar Operators. Helm does not upgrade Custom Resource Definitions (CRDs) when you use the `helm upgrade` command. Therefore, you must manually upgrade the associated CRDs before upgrading the chart.

<Note title="Note">
  If you use the Operator Lifecycle Manager (OLM) to install the Pulsar Operators, you don’t need to manually upgrade the Pulsar Operators. The OLM periodically checks if there is new version available and automatically upgrades the Pulsar Operators.
</Note>

This document demonstrates how to upgrade the Pulsar Operators.

## Prerequisites

* You have installed the Pulsar Operators using the Helm chart.
* Install [Helm](https://helm.sh/docs/intro/install/) (v3.0.2 or above).

## Steps

1. View the existing version of the Pulsar Operators running on your Kubernetes cluster.

   ```bash theme={null}
   helm ls -n <k8s-namespace> | grep pulsar-operator
   ```

   The sample output shoule be as follows. Both the chart version and the application version are `0.14.0`.

   ```bash theme={null}
   pulsar-operators	operators	1       	2023-03-13 17:19:01.754639 +0800 CST	deployed	pulsar-operator-0.14.0	0.14.0
   ```

2. View the latest available version of the Pulsar Operators.

   ```bash theme={null}
   helm repo update
   helm search repo streamnative/pulsar-operator --versions
   ```

   You should see the following output:

   ```bash theme={null}
   NAME                        	CHART VERSION	APP VERSION	DESCRIPTION
   streamnative/pulsar-operator	0.15.0       	0.15.2     	Apache Pulsar Operator Helm chart for Kubernetes
   streamnative/pulsar-operator	0.14.2       	0.14.0     	Apache Pulsar Operator Helm chart for Kubernetes
   streamnative/pulsar-operator	0.14.1       	0.14.0     	Apache Pulsar Operator Helm chart for Kubernetes
   streamnative/pulsar-operator	0.14.0       	0.14.0     	Apache Pulsar Operator Helm chart for Kubernetes
   ```

3. Upgrade the CRDs of the Pulsar Operators.
   The following commands upgrade the CRDs to their latest versions.

   ```bash theme={null}
   # Upgrade the broker CRD.
   kubectl replace -f https://raw.githubusercontent.com/streamnative/charts/master/charts/pulsar-operator/crds/pulsar.streamnative.io_pulsarbrokers.yaml

   # Upgrade the proxy CRD.
   kubectl replace -f https://raw.githubusercontent.com/streamnative/charts/master/charts/pulsar-operator/crds/pulsar.streamnative.io_pulsarproxies.yaml

   # Upgrade the BookKeeper CRD.
   kubectl replace -f https://raw.githubusercontent.com/streamnative/charts/master/charts/pulsar-operator/crds/bookkeeper.streamnative.io_bookkeeperclusters.yaml

   # Upgrade the ZooKeeper CRD.
   kubectl replace -f https://raw.githubusercontent.com/streamnative/charts/master/charts/pulsar-operator/crds/zookeeper.streamnative.io_zookeeperclusters.yaml
   ```

4. Upgrade the Pulsar Operators.
   This command deletes the existing Pods and creates new ones.

   ```bash theme={null}
   helm upgrade <release-name> -n <k8s-namespace> streamnative/pulsar-operator
   ```

5. Verify that the Pulsar Operators are upgraded successfully.

   ```bash theme={null}
   kubectl get pods -n <k8s-namespace>
   ```

   You should see the following output:

   ```bash theme={null}
   NAME                                                             READY   STATUS    RESTARTS   AGE
   pulsar-operators-bookkeeper-controller-manager-b469d56-xpzdq     1/1     Running   0          29s
   pulsar-operators-pulsar-controller-manager-596d6878d6-zb5q4      1/1     Running   0          29s
   pulsar-operators-zookeeper-controller-manager-67cdb945cb-cgj4d   1/1     Running   0          29s
   ```

6. View the version of Pulsar Operators.

   ```bash theme={null}
   helm ls -n <k8s-namespace> | grep pulsar-operator
   ```

   The sample output shoule be as follows. The latest chart version and the application version have been installed.

   ```bash theme={null}
   pulsar-operators	operators	2       	2023-03-13 17:37:49.606714 +0800 CST	deployed	pulsar-operator-0.15.0	0.15.2
   ```

## Related topics

* [Install the Pulsar Operators using the Helm chart](/tools/operator/quickstart-guides/pulsar-operator-install-helm-chart).
* [Install the Pulsar Operators using the Operator Lifecycle Manager](/tools/operator/quickstart-guides/pulsar-operator-install-olm).
* [Uninstall the Pulsar Operators](id:pulsar-operator-uninstall.)
