Yandex.Cloud
  • Services
  • Why Yandex.Cloud
  • Pricing
  • Documentation
  • Contact us
Get started
Yandex Compute Cloud
  • Getting started
    • Overview
    • Creating a Linux VM
    • Creating a Windows VM
    • Creating instance groups
  • Step-by-step instructions
    • All instructions
    • Creating VMs
      • Creating a Linux VM
      • Creating a Windows VM
      • Creating a VM from a set of disks
      • Creating a VM with disks restored from snapshots
      • Creating a VM from a custom image
      • Creating a preemptible VM
      • Creating a VM with a GPU
    • DSVM
      • Overview
      • Creating a VM from a public DSVM image
    • Placement groups
      • Creating a placement group
      • Deleting a placement group
      • Creating a VM in a placement group
      • Adding a VM to a placement group
      • Removing a VM instance from a placement group
    • Images with pre-installed software
      • Creating a VM from a public image
      • Configuring software
      • Working with a VM based on a public image
      • Getting a list of public images
    • Getting information about a VM
      • Getting information about a VM
      • Viewing serial port output
    • Managing VMs
      • Stopping and starting a VM
      • Attaching a disk to a VM
      • Detaching a disk from a VM
      • Moving a VM to a different availability zone
      • Making a VM's public IP address static
      • Updating a VM
      • Changing VM computing resources
      • Deleting a VM
    • Working on VMs
      • Connecting to a VM via SSH
      • Connecting to a VM via RDP
      • Working with Yandex.Cloud from inside a VM
      • Installing NVIDIA drivers
    • Creating new disks
      • Creating an empty disk
      • Create an empty disk with a large block
    • Disk management
      • Creating a disk snapshot
      • Updating a disk
      • Deleting a disk
      • Deleting a disk snapshot
    • Creating new images
      • Uploading your image
    • Managing images
      • Deleting a disk image
    • Managing the serial console
      • Getting started
      • Connecting to a serial console via SSH
      • Connecting to a serial console via CLI
      • Start your terminal in the Windows SAC
      • Disabling access to the serial console
    • Creating instance groups
      • Creating a fixed-size instance group
      • Creating a fixed-size instance group with a network load balancer
      • Creating an automatically scaled instance group
      • Creating an instance group from Container Optimized Image
    • Getting information about instance groups
      • Getting a list of instance groups
      • Getting information about an instance group
      • Getting a list of instances in a group
    • Managing instance groups
      • Editing an instance group
      • Configuring application health check on the VM
      • Updating a instance group
        • Incremental updates
        • Uninterrupted updates
      • Stopping an instance group
      • Starting an instance group
      • Deleting an instance group
    • Dedicated hosts
      • Creating a VM in a group of dedicated hosts
      • Creating a VM on a dedicated host
  • Yandex Container Optimized Solutions
  • Scenarios
    • Configuring NTP time synchronization
    • Running instance groups with auto scaling
  • Concepts
    • Relationship between resources
    • Virtual machines
      • Overview
      • Platforms
      • vCPU performance levels
      • Graphics accelerators (GPUs)
      • Preemptible VMs
      • Network on a VM
      • Live migration
      • Placement groups
      • Statuses
      • Metadata
    • Disks
      • Overview
      • Disk snapshots
    • Images
    • Instance groups
      • Overview
      • Access
      • Instance template
      • Variables in an instance template
      • Policies
        • Overview
        • Allocation policy
        • Deployment policy
        • Scaling policy
      • Scaling types
      • Auto-healing
      • Updating
        • Overview
        • Allocating instances across zones
        • Deployment algorithm
        • Rules for updating instance groups
      • Statuses
    • Dedicated host
    • Backups
    • Quotas and limits
  • Access management
  • Pricing policy
    • Current pricing policy
    • Archive
      • Before January 1, 2019
      • From January 1 to March 1, 2019
      • From March 1 to May 1, 2019
  • Compute API reference
    • Authentication in the API
    • gRPC
      • Overview
      • DiskPlacementGroupService
      • DiskService
      • DiskTypeService
      • HostGroupService
      • HostTypeService
      • ImageService
      • InstanceService
      • PlacementGroupService
      • SnapshotService
      • ZoneService
      • InstanceGroupService
      • OperationService
    • REST
      • Overview
      • Disk
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • update
      • DiskPlacementGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listDisks
        • listOperations
        • update
      • DiskType
        • Overview
        • get
        • list
      • HostGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listHosts
        • listInstances
        • listOperations
        • update
      • HostType
        • Overview
        • get
        • list
      • Image
        • Overview
        • create
        • delete
        • get
        • getLatestByFamily
        • list
        • listOperations
        • update
      • Instance
        • Overview
        • addOneToOneNat
        • attachDisk
        • create
        • delete
        • detachDisk
        • get
        • getSerialPortOutput
        • list
        • listOperations
        • removeOneToOneNat
        • restart
        • start
        • stop
        • update
        • updateMetadata
        • updateNetworkInterface
      • PlacementGroup
        • Overview
        • create
        • delete
        • get
        • list
        • listInstances
        • listOperations
        • update
      • Snapshot
        • Overview
        • create
        • delete
        • get
        • list
        • listOperations
        • update
      • Zone
        • Overview
        • get
        • list
      • Operation
        • Overview
        • get
      • InstanceGroup
        • Overview
        • createFromYaml
        • update
        • list
        • get
        • delete
        • start
        • stop
        • create
        • listAccessBindings
        • setAccessBindings
        • updateFromYaml
        • listLogRecords
        • listInstances
        • updateAccessBindings
        • listOperations
  • Questions and answers
    • General questions
    • Virtual machines
    • Disks and snapshots
    • Licensing
    • All questions on the same page
  1. Concepts
  2. Instance groups
  3. Policies
  4. Scaling policy

Scaling policy

  • fixed_scale
  • auto_scale

When creating an instance group, you can choose how to increase and decrease the number of instances in the group.

The policy is defined in the scale-policy key in the YAML file.

fixed_scale

The fixed_scale key defines a group of fixed-size instances. The size of the group is defined in the size key. You can create a group with the desired number of instances within the available quotas and limits.

Example of a YAML file entry:

...
scale_policy:
    fixed_scale:
        size: 3
...

Keys:

Key Value
fixed_scale A group of fixed-size instances.
size* Number of instances in the group.
Valid values are from 0 to 100.

* Required field.

auto_scale

The auto_scale key defines automatically scalable instance group. The initial size of the group is defined in the initial_size key. You can create a group with the desired number of instances within the available quotas and limits.

Example of a YAML file entry:

scale_policy:
    auto_scale:
        initial_size: 5
        max_size: 15
        min_zone_size: 3
        measurement_duration: 30
        warmup_duration: 60
        stabilization_duration: 120
        cpu_utilization_rule:
            utilization_target: 75

Keys:

Key Value
auto_scale An automatically scaled instance group.
initial_size* Initial number of instances in the group.
Valid values are from 0 to 100.
max_size Maximum number of instances in the group.
Valid values are from 0 to 100.
min_zone_size Minimum number of instances in one availability zone.
Valid values are from 0 to 100.
measurement_duration* Time in seconds allotted for averaging metrics based on CPU load. If the average load at the end of the interval is higher than cpu_utilization_rule.utilization_target, Instance Groups increases the number of instances in the group.
Valid values are from 60 to 600 seconds.
warmup_duration* The warmup time of the instance. During this time, traffic is sent to the instance, but CPU utilization metrics aren't considered.
Valid values are from 0 to 600 seconds.
stabilization_duration* The minimum amount of time to monitor CPU utilization before Instance Groups can reduce the number of instances in the group. During this time, the group is not resized, even if the average CPU utilization drops below the cpu_utilization_rule.utilization_target value.
Valid values are from 60 to 1800 seconds.
cpu_utilization_rule* Sets the target CPU utilization to run scaling based on the average CPU utilization in the instance group.
utilization_target* Target CPU utilization to be supported by Instance Groups.
If the average CPU utilization is below the target value, Instance Groups will reduce the number of instances until it reaches min_zone_size in each availability zone.
If the average CPU utilization is higher than the target value, Instance Groups will create instances until it reaches max_size.
Valid values are from 10 to 100.

* Required field.

In this article:
  • fixed_scale
  • auto_scale
Language
Careers
Privacy policy
Terms of use
© 2021 Yandex.Cloud LLC