KubeBlocks
BlogsKubeBlocks Cloud
⌘K
​

Overview

Introduction
Concepts
Kubernetes and Operator 101
Supported addons
About this manual

Try out KubeBlocks with Playground

Try out KubeBlocks on cloud
Try out KubeBlocks on laptop

Installation

Prerequisite for Local Env

Prerequisite for Local Env
Install kbcli
Install KubeBlocks
Install Addons
Uninstall KubeBlocks and kbcli

Upgrade KubeBlocks

Upgrade to v0.8
Upgrade to v0.9.0
Upgrade to v0.9.3
FAQ

Connect Database

Overview
Testing environment
Production environment

Maintenance

Scale

Horizontal Scale
Vertical Scale

Backup and Restore

Introduction

Backup

Configure BackupRepo
Configure BackupPolicy
Scheduled backup
On-demand backup

Restore

Restore from backup set
PITR

In Place Update

Overview on in-place update
Enable in-place update

Resource Scheduling

Configure pod affinity for database clusters

Cross K8s Deployment

Deploy a Cluster across Multiple Kubernetes Clusters by KubeBlocks

Instance Template

Introduction of instance template
Apply instance template

Observability

Monitor database
Configure alert

User Management

Manage user accounts

Handle an Exception

Handle an exception
Full disk lock

Developer

Developer guides
Terminology

Add an add-on to KubeBlocks

Add-ons of KubeBlocks
Add an add-on
Backup and restore
Parameter template
Parameter configuration
Monitoring
Multi-component configuration
Environment variables and placeholders

External Component

Reference external component

API Reference

Cluster
Backup
Add-On
  1. Compatibility
  2. Upgrade from KubeBlocks v0.8
  3. Upgrade Addons
  4. FAQ

Upgrade to KubeBlocks v0.9.0

In this tutorial, you will learn how to upgrade to KubeBlocks v0.9.0.

NOTE

Execute helm -n kb-system list | grep kubeblocks or kbcli version to check the current KubeBlocks version you are running, and then upgrade KubeBlocks.

Compatibility

KubeBlocks 0.9.0 is compatible with KubeBlocks 0.8 APIs, but compatibility with APIs from versions prior to v0.8 is not guaranteed. If you are using Addons from KubeBlocks 0.7 or earlier (0.6, etc), DO upgrade KubeBlocks and all Addons to v0.8 first to ensure service availability before upgrading to v0.9.0.

Upgrade from KubeBlocks v0.8

  1. Add the "helm.sh/resource-policy": "keep" for Addons.

    KubeBlocks v0.8 streamlines the default installed engines. To avoid deleting Addon resources that are already in use during the upgrade, execute the following commands first.

    • Add the "helm.sh/resource-policy": "keep" for Addons. You can replace -l app.kubernetes.io/name=kubeblocks with your actual filter name.

      kubectl annotate addons.extensions.kubeblocks.io -l app.kubernetes.io/name=kubeblocks helm.sh/resource-policy=keep
      
    • Check Addons.

      Execute the following command to ensure that the Addon annotations contain "helm.sh/resource-policy": "keep".

      kubectl get addon -o json | jq '.items[] | {name: .metadata.name, annotations: .metadata.annotations}'
      
  2. Delete the incompatible OpsDefinition.

    kubectl delete opsdefinitions.apps.kubeblocks.io kafka-quota kafka-topic kafka-user-acl switchover
    
  3. Install the StorageProvider CRD before the upgrade.

    If the network is slow, it's recommended to download the CRD YAML file on your localhost before further operations.

    kubectl create -f https://github.com/apecloud/kubeblocks/releases/download/v0.9.0/dataprotection.kubeblocks.io_storageproviders.yaml
    
  4. Upgrade KubeBlocks.

    helm -n kb-system upgrade kubeblocks kubeblocks/kubeblocks --version 0.9.0
    
    NOTE

    To avoid affecting existing database clusters, when upgrading to KubeBlocks v0.9.0, the versions of already-installed Addons will not be upgraded by default. If you want to upgrade the Addons to the versions built into KubeBlocks v0.9.0, execute the following command. Note that this may restart existing clusters and affect availability. Please proceed with caution.

    helm -n kb-system upgrade kubeblocks kubeblocks/kubeblocks --version 0.9.0 \
    --set upgradeAddons=true
    
  1. Download kbcli v0.9.0.

    curl -fsSL https://kubeblocks.io/installer/install_cli.sh | bash -s 0.9.0
    
  2. Upgrade KubeBlocks.

    kbcli kb upgrade --version 0.9.0
    
    NOTE

    To avoid affecting existing database clusters, when upgrading to KubeBlocks v0.9.0, the versions of already-installed Addons will not be upgraded by default. If you want to upgrade the Addons to the versions built into KubeBlocks v0.9.0, execute the following command. Note that this may restart existing clusters and affect availability. Please proceed with caution.

    kbcli kb upgrade --version 0.9.0 --set upgradeAddons=true
    

    kbcli will automatically add the annotation "helm.sh/resource-policy": "keep" to ensure that existing Addons are not deleted during the upgrade.

Upgrade Addons

If you didn't specify upgradeAddons as true or your Addon is not included in the default installed Addons, you can upgrade Addons by running the commands provided below to use the v0.9.0 API.

NOTE

If the Addon you want to upgrade is mysql, you need to upgrade this Addon and restart the cluster. Otherwise, the cluster created in KubeBlocks v0.8 cannot be used in v0.9.0.

If the Addon you want to use is clickhouse/milvus/elasticsearch/llm, you need to upgrade KubeBlocks first and then upgrade this Addon. Otherwise, these Addons cannot be used in KubeBlocks v0.9.0 normally.

# Add Helm repo
helm repo add kubeblocks-addons https://apecloud.github.io/helm-charts

# If github is not accessible or very slow for you, please use following repo instead
helm repo add kubeblocks-addons https://jihulab.com/api/v4/projects/150246/packages/helm/stable

# Update helm repo
helm repo update

# Update Addon version
helm upgrade -i {addon-release-name} kubeblocks-addons/{addon-name} --version x.y.z -n kb-system
# View the Addon index list
kbcli addon index list

# Update one index and the default index is kubeblocks
kbcli addon index update kubeblocks

# Search available Addon versions
kbcli addon search <addonName>

# Install an Addon
kbcli addon install <addonName> --version x.y.z

# Upgrade this Addon to a specified version
kbcli addon upgrade <addonName> --version x.y.z

# Force to upgrade to a specified version
kbcli addon upgrade <addonName> --version x.y.z --force

# View the available Addon versions
kbcli addon list | grep <addonName>

FAQ

Refer to the FAQ to address common questions and issues that may arise when upgrading KubeBlocks. If your question isn't covered, you can submit an issue or start a discussion on upgrading on GitHub.

© 2025 ApeCloud PTE. Ltd.