Yandex Cloud
Search
Contact UsTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Yandex Managed Service for Kubernetes
  • Comparing with other Yandex Cloud services
  • Getting started
    • All guides
    • Connecting to a node over SSH
    • Connecting to a node via OS Login
    • Updating Kubernetes
    • Configuring autoscaling
    • Activating a Kubernetes Terraform provider
    • Installing applications from Yandex Cloud Marketplace using Terraform
    • Working with private Docker image registries
      • Information about existing node groups
      • Creating a node group
      • Creating a group with nodes from a reserved instance pool
      • Connecting to a node over SSH
      • Connecting to a node via OS Login
      • Configuring autoscaling
      • Updating a node group
      • Managing Kubernetes node labels
      • Deleting a node group
  • Access management
  • Pricing policy
  • Terraform reference
  • Monitoring metrics
  • Audit Trails events
  • Release notes

In this article:

  • Creating a node group in a single availability zone with nodes from a reserved instance pool in that zone
  • Creating a node group in three availability zones with nodes from reserved instance pools in each zone
  • See also
  1. Step-by-step guides
  2. Managing a node group
  3. Creating a group with nodes from a reserved instance pool

Creating a group with nodes from a Yandex Compute Cloud reserved instance pool

Written by
Yandex Cloud
Updated at April 28, 2026
  • Creating a node group in a single availability zone with nodes from a reserved instance pool in that zone
  • Creating a node group in three availability zones with nodes from reserved instance pools in each zone
    • See also

Warning

Reserved instance pools are billable: you pay for the whole unused volume of reserved computing resources of VMs, GPU clusters, and software accelerated networks according to the Yandex Compute Cloud pricing policy. For more information, see Using reserved instance pools.

The reserved instance pool feature is at the Preview stage.

A reserved instance pool is the total of computing resources reserved by the user in a given availability zone to secure their guaranteed availability to the user for the purpose of creating VMs of a particular configuration in this availability zone.

In Managed Service for Kubernetes, you can use reserved instance pools for fixed-size node groups. This ensures resource availability for cluster nodes.

For more information, see Reserved instance pools for Yandex Managed Service for Kubernetes node groups and Reserved instance pools in Compute Cloud.

Warning

Reserved instance pools are not supported for node groups with the following properties:

  • Autoscaling
  • vCPU performance levels below 100%
  • Preemptible VMs
  • VM placement groups

Creating a node group in a single availability zone with nodes from a reserved instance pool in that zoneCreating a node group in a single availability zone with nodes from a reserved instance pool in that zone

  1. Create a reserved instance pool with a configuration you want to use for Managed Service for Kubernetes cluster nodes.

    Note

    Make sure the following properties are identical in the node group and reserved instance pool configurations:

    • Platform
    • Number of vCPUs
    • Amount of RAM
    • Availability zone

    The number of group nodes in each availability zone must not exceed the size of the reserved instance pools in those zones.

  2. Create a Managed Service for Kubernetes cluster.

  3. Create a node group:

    CLI
    Terraform

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

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

    In the terminal, run this command:

    yc managed-kubernetes node-group create \
      --name k8s-reserved-ng \
      --cluster-id <cluster_ID> \
      --platform-id standard-v4a \
      --cores 4 \
      --memory 8 \
      --disk-size 64 \
      --disk-type network-ssd \
      --fixed-size 2 \
      --location zone=ru-central1-a,subnet-id=<subnet_ID> \
      --network-interface security-group-ids=[<security_group_IDs>] \
      --reserved-instance-pool-id <reserved_instance_pool_ID>
    

    Where:

    • --cluster-id: Cluster ID.
    • --location: Availability zone and subnet ID.
    • --network-interface security-group-ids: Security group IDs.
    • --reserved-instance-pool-id: Reserved instance pool ID.

    For more information about this command, see the CLI reference.

    If you do not have Terraform yet, install it and configure the Yandex Cloud provider.

    1. In the configuration file, describe the node group parameters:

      resource "yandex_kubernetes_node_group" "k8s-reserved-ng" {
        cluster_id = "<cluster_ID>"
        name       = "k8s-reserved-ng"
      
        instance_template {
          platform_id = "standard-v4a"
          reserved_instance_pool_id = "<reserved_instance_pool_ID>"
      
          resources {
            cores  = 4
            memory = 8
          }
      
          boot_disk {
            size = 64
            type = "network-ssd"
          }
      
          network_interface {
            subnet_ids = ["<subnet_ID>"]
            security_group_ids = ["<security_group_IDs>"]
            nat        = true
          }
        }
      
        scale_policy {
          fixed_scale {
            size = 2
          }
        }
      
        allocation_policy {
          location {
            zone = "ru-central1-a"
          }
        }
      }
      

      Where:

      • cluster_id: Cluster ID.
      • subnet_ids: Subnet ID.
      • security_group_ids: Security group IDs.
      • reserved_instance_pool_id: Reserved instance pool ID.
    2. Create a node group:

      1. In the terminal, navigate to the configuration file directory.

      2. Make sure the configuration is correct using this command:

        terraform validate
        

        If the configuration is valid, you will get this message:

        Success! The configuration is valid.
        
      3. Run this command:

        terraform plan
        

        You will see a list of resources and their properties. No changes will be made at this step. Terraform will show any errors in the configuration.

      4. Apply the configuration changes:

        terraform apply
        
      5. Type yes and press Enter to confirm the changes.

    For more information about yandex_kubernetes_node_group, see this Terraform reference.

Creating a node group in three availability zones with nodes from reserved instance pools in each zoneCreating a node group in three availability zones with nodes from reserved instance pools in each zone

  1. Create a reserved instance pool with a configuration you want to use for Managed Service for Kubernetes cluster nodes.

    Note

    Make sure the following properties are identical in the node group and reserved instance pool configurations:

    • Platform
    • Number of vCPUs
    • Amount of RAM
    • Availability zone

    The number of group nodes in each availability zone must not exceed the size of the reserved instance pools in those zones.

  2. Create a Managed Service for Kubernetes cluster.

  3. Create a node group:

    Tip

    Reserved instance pools are created in a specific availability zone. To automate the distribution of multi-zone group nodes across reserved instance pools of a specific availability zone, use the node template variables.

    CLI
    Terraform

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

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

    In the terminal, run this command:

    yc managed-kubernetes node-group create \
      --name k8s-multizone-reserved-ng \
      --cluster-id <cluster_ID> \
      --platform-id standard-v4a \
      --cores 4 \
      --memory 8 \
      --disk-size 64 \
      --disk-type network-ssd \
      --fixed-size 3 \
      --location zone=ru-central1-a,subnet-id=<subnet_ID_in_zone_a> \
      --location zone=ru-central1-b,subnet-id=<subnet_ID_in_zone_b> \
      --location zone=ru-central1-d,subnet-id=<subnet_ID_in_zone_d> \
      --network-interface security-group-ids=[<security_group_IDs>] \
      --reserved-instance-pool-id '{pool_{instance.zone_id}}' \
      --variables \
    pool_ru-central1-a=<pool_ID_in_zone_a>,\
    pool_ru-central1-b=<pool_ID_in_zone_b>,\
    pool_ru-central1-d=<pool_ID_in_zone_d>
    

    Where:

    • --cluster-id: Cluster ID.
    • --location: Availability zones and their relevant subnet IDs.
    • --network-interface security-group-ids: Security group IDs.
    • --reserved-instance-pool-id: Reserved instance pool IDs you will get as a result of substituting the instance.zone_id system variable (availability zone of a specific node) and the user-defined variables specified in the --variables parameter.
    • --variables: User-defined variables with IDs of reserved instance pools in different availability zones.

    For more information about this command, see the CLI reference.

    If you do not have Terraform yet, install it and configure the Yandex Cloud provider.

    1. In the configuration file, describe the node group parameters:

      resource "yandex_kubernetes_node_group" "k8s-multizone-reserved-ng" {
        cluster_id = "<cluster_ID>"
        name       = "k8s-multizone-reserved-ng"
      
        # Variables for reserved instance pools
        variables = {
          pool_ru-central1-a = "<reserved_instance_pool_ID_in_zone_a>"
          pool_ru-central1-b = "<reserved_instance_pool_ID_in_zone_b>"
          pool_ru-central1-d = "<reserved_instance_pool_ID_in_zone_d>"
        }
      
        instance_template {
          name = "test-{instance.zone_id}-{instance.index}"
          # instance.zone_id: System variable with the zone ID
          reserved_instance_pool_id = "{pool_{instance.zone_id}}"
          platform_id = "standard-v4a"
      
          resources {
            cores = 4
            memory = 8
          }
      
          boot_disk {
            size = 64
            type = "network-ssd"
          }
      
          network_interface {
            nat = true
            subnet_ids = [
              "<subnet_ID_in_zone_a>",
              "<subnet_ID_in_zone_b>",
              "<subnet_ID_in_zone_d>"
            ]
            security_group_ids = ["<security_group_IDs>"]
          }
        }
      
        scale_policy {
          fixed_scale {
            size = 3
          }
        }
      
        allocation_policy {
          location {
            zone = "ru-central1-a"
          }
      
          location {
            zone = "ru-central1-b"
          }
      
          location {
            zone = "ru-central1-d"
          }
        }
      }
      

      Where:

      • cluster_id: Cluster ID.
      • variables: User-defined variables with IDs of reserved instance pools in different availability zones.
      • name: Node name in the group, generated using the following system variables: instance.zone_id (the node’s availability zone) and instance.index (unique node number in the group, starting from 1).
      • reserved_instance_pool_id: Reserved instance pool IDs you will get as a result of substituting the instance.zone_id system variable and the user-defined variables specified in the variables parameter.
      • subnet_ids: Subnet IDs.
      • security_group_ids: Security group IDs.
    2. Create a node group:

      1. In the terminal, navigate to the configuration file directory.

      2. Make sure the configuration is correct using this command:

        terraform validate
        

        If the configuration is valid, you will get this message:

        Success! The configuration is valid.
        
      3. Run this command:

        terraform plan
        

        You will see a list of resources and their properties. No changes will be made at this step. Terraform will show any errors in the configuration.

      4. Apply the configuration changes:

        terraform apply
        
      5. Type yes and press Enter to confirm the changes.

    For more information about yandex_kubernetes_node_group, see this Terraform reference.

See alsoSee also

  • Reserved instance pools for Yandex Managed Service for Kubernetes node groups
  • Variables in a Yandex Managed Service for Kubernetes node template
  • Reserved instance pools in Compute Cloud
  • Working with reserved instance pools
  • Variables in an instance template
  • Creating a node group

Was the article helpful?

Previous
Creating a node group
Next
Connecting to a node over SSH
© 2026 Direct Cursus Technology L.L.C.