Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
  • Blog
  • Pricing
  • Documentation
Yandex project
© 2025 Yandex.Cloud LLC
Yandex Managed Service for ClickHouse®
  • Getting started
    • All guides
      • Information about existing clusters
      • Creating a cluster
      • Updating cluster settings
      • ClickHouse® version upgrade
      • Stopping and starting a cluster
      • Managing backups
      • Deleting a cluster
  • Access management
  • Terraform reference
  • Yandex Monitoring metrics
  • Audit Trails events
  • Public materials
  • Release notes

In this article:

  • List of available versions
  • Before a version upgrade
  • Updating the version
  1. Step-by-step guides
  2. Clusters
  3. ClickHouse® version upgrade

ClickHouse® version upgrade

Written by
Yandex Cloud
Updated at May 5, 2025
  • List of available versions
  • Before a version upgrade
  • Updating the version

You can change the ClickHouse® version used by the cluster to any of the supported Managed Service for ClickHouse® versions.

To learn more about updates within a single version and host maintenance, see Maintenance.

List of available versionsList of available versions

Management console
CLI
REST API
gRPC API

In the management console, open the Managed Service for OpenSearch cluster create or update page. You can view the list in the Version field.

If you do not have the Yandex Cloud CLI yet, install and initialize it.

The folder specified when creating the CLI profile is used by default. To change the default folder, use the yc config set folder-id <folder_ID> command. You can specify a different folder using the --folder-name or --folder-id parameter.

To get a list of available versions, run the following command:

yc managed-clickhouse version list
  1. Get an IAM token for API authentication and put it into the environment variable:

    export IAM_TOKEN="<IAM_token>"
    
  2. Use the Versions.List method and send the following request, e.g., via cURL:

    curl \
        --request GET \
        --header "Authorization: Bearer $IAM_TOKEN" \
        --url 'https://mdb.api.cloud.yandex.net/managed-clickhouse/v1/versions'
    
  3. View the server response to make sure the request was successful.

  1. Get an IAM token for API authentication and put it into the environment variable:

    export IAM_TOKEN="<IAM_token>"
    
  2. Clone the cloudapi repository:

    cd ~/ && git clone --depth=1 https://github.com/yandex-cloud/cloudapi
    

    Below, we assume the repository contents are stored in the ~/cloudapi/ directory.

  3. Use the VersionsService.List call and send the following request, e.g., via gRPCurl:

    grpcurl \
        -format json \
        -import-path ~/cloudapi/ \
        -import-path ~/cloudapi/third_party/googleapis/ \
        -proto ~/cloudapi/yandex/cloud/mdb/clickhouse/v1/versions_service.proto \
        -rpc-header "Authorization: Bearer $IAM_TOKEN" \
        mdb.api.cloud.yandex.net:443 \
        yandex.cloud.mdb.clickhouse.v1.VersionsService.List
    
  4. View the server response to make sure the request was successful.

Before a version upgradeBefore a version upgrade

Make sure this does not affect your applications:

  1. See the ClickHouse® changelog to check how updates might affect your applications.
  2. Try a version upgrade on a test cluster. You can deploy it from a backup of the main cluster. In this case, you will only recover MergeTree tables.
  3. Create a backup of the main cluster directly before the version upgrade.

Updating the versionUpdating the version

Management console
CLI
Terraform
REST API
gRPC API
  1. In the management console, open the Managed Service for ClickHouse page in the folder where you want to update the ClickHouse® version.
  2. In the list of clusters, select the one to change.
  3. Click Edit.
  4. Under Basic parameters, select the appropriate version in the Version field.
  5. Click Save changes.

When the change starts, the cluster status will switch to UPDATING. Wait for the operation to complete and then check the cluster version.

If you do not have the Yandex Cloud CLI yet, install and initialize it.

The folder specified when creating the CLI profile is used by default. To change the default folder, use the yc config set folder-id <folder_ID> command. You can specify a different folder using the --folder-name or --folder-id parameter.

  1. Get a list of your ClickHouse® clusters and view their versions:

    yc managed-clickhouse cluster list
    
    +----------------------+------+-------------+---------+---------------------+--------+---------+
    |          ID          | NAME | ENVIRONMENT | VERSION |     CREATED AT      | HEALTH | STATUS  |
    +----------------------+------+-------------+---------+---------------------+--------+---------+
    | c9qf1kmm0ebi******** | mych | PRODUCTION  |    23.8 | 2024-06-06 10:23:22 | ALIVE  | RUNNING |
    +----------------------+------+-------------+---------+---------------------+--------+---------+
    
  2. Update the ClickHouse® version for any cluster as needed:

    yc managed-clickhouse cluster update --id <cluster_ID> --version <ClickHouse®_version>
    

    Specify the ClickHouse® version: 24.3, 24.8, 24.9, or 24.10.

When the update starts, the cluster status will switch to UPDATING. Wait for the operation to complete and then check the cluster version.

  1. Open the current Terraform configuration file with an infrastructure plan.

    For more information about creating this file, see Creating clusters.

  2. To the Managed Service for ClickHouse® cluster description, add the version field or change its value if it is already there:

    resource "yandex_mdb_clickhouse_cluster" "<cluster_name>" {
      ...
      version = "<ClickHouse®_version>"
    }
    

    Specify the ClickHouse® version: 24.3, 24.8, 24.9, or 24.10.

  3. Make sure the settings are correct.

    1. In the command line, navigate to the directory that contains the current Terraform configuration files defining the infrastructure.

    2. Run this command:

      terraform validate
      

      Terraform will show any errors found in your configuration files.

  4. Confirm updating the resources.

    1. Run this command to view the planned changes:

      terraform plan
      

      If you described the configuration correctly, the terminal will display a list of the resources to update and their parameters. This is a verification step that does not apply changes to your resources.

    2. If everything looks correct, apply the changes:

      1. Run this command:

        terraform apply
        
      2. Confirm updating the resources.

      3. Wait for the operation to complete.

For more information, see the Terraform provider documentation.

Time limits

A Terraform provider sets the timeout for Managed Service for ClickHouse® cluster operations:

  • Creating a cluster, including by restoring one from a backup: 60 minutes.
  • Editing a cluster: 90 minutes.
  • Deleting a cluster: 30 minutes.

Operations exceeding the set timeout are interrupted.

How do I change these limits?

Add the timeouts block to the cluster description, for example:

resource "yandex_mdb_clickhouse_cluster" "<cluster_name>" {
  ...
  timeouts {
    create = "1h30m" # 1 hour 30 minutes
    update = "2h"    # 2 hours
    delete = "30m"   # 30 minutes
  }
}
  1. Get an IAM token for API authentication and put it into the environment variable:

    export IAM_TOKEN="<IAM_token>"
    
  2. Use the Cluster.Update method and send the following request, e.g., via cURL:

    Warning

    The API method will assign default values to all the parameters of the object you are modifying unless you explicitly provide them in your request. To avoid this, list the settings you want to change in the updateMask parameter as a single comma-separated string.

    curl \
        --request PATCH \
        --header "Authorization: Bearer $IAM_TOKEN" \
        --header "Content-Type: application/json" \
        --url 'https://mdb.api.cloud.yandex.net/managed-clickhouse/v1/clusters/<cluster_ID>' \
        --data '{
                  "updateMask": "configSpec.version",
                  "configSpec": {
                    "version": "<ClickHouse®>_version"
                  }
                }'
    

    Where:

    • updateMask: List of parameters to update as a single string, separated by commas.

      Here only one parameter is specified: configSpec.version.

    • configSpec.version: target ClickHouse® version, 24.3, 24.8, 24.9, or 24.10.

    You can get the cluster ID with a list of clusters in the folder.

  3. View the server response to make sure the request was successful.

  1. Get an IAM token for API authentication and put it into the environment variable:

    export IAM_TOKEN="<IAM_token>"
    
  2. Clone the cloudapi repository:

    cd ~/ && git clone --depth=1 https://github.com/yandex-cloud/cloudapi
    

    Below, we assume the repository contents are stored in the ~/cloudapi/ directory.

  3. Use the ClusterService.Update call and send the following request, e.g., via gRPCurl:

    Warning

    The API method will assign default values to all the parameters of the object you are modifying unless you explicitly provide them in your request. To avoid this, list the settings you want to change in the update_mask parameter as an array of paths[] strings.

    Format for listing settings
    "update_mask": {
        "paths": [
            "<setting_1>",
            "<setting_2>",
            ...
            "<setting_N>"
        ]
    }
    
    grpcurl \
        -format json \
        -import-path ~/cloudapi/ \
        -import-path ~/cloudapi/third_party/googleapis/ \
        -proto ~/cloudapi/yandex/cloud/mdb/clickhouse/v1/cluster_service.proto \
        -rpc-header "Authorization: Bearer $IAM_TOKEN" \
        -d '{
              "cluster_id": "<cluster_ID>",
              "update_mask": {
                "paths": [
                  "config_spec.version"
                ]
              },
              "config_spec": {
                "version": "<ClickHouse®>_version"
              }
            }' \
        mdb.api.cloud.yandex.net:443 \
        yandex.cloud.mdb.clickhouse.v1.ClusterService.Update
    

    Where:

    • update_mask: List of parameters to update as an array of paths[] strings.

      Here only one parameter is specified: config_spec.version.

    • config_spec.version: target ClickHouse® version, 24.3, 24.8, 24.9, or 24.10.

    You can get the cluster ID with a list of clusters in the folder.

  4. View the server response to make sure the request was successful.

ClickHouse® is a registered trademark of ClickHouse, Inc.

Was the article helpful?

Previous
Query level
Next
Stopping and starting a cluster
Yandex project
© 2025 Yandex.Cloud LLC