Project

General

Profile

Bug #14382

OnDemand: Question about size of auto-scale group when using gcloud

Added by Neha Sharma almost 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
High
Assignee:
Start date:
11/03/2016
Due date:
11/07/2016
% Done:

100%

Estimated time:
2.00 h
Duration: 5

Description

This issue is seen when using gcloud to create an auto-scaling/managed instance group.

According to output of "gcloud compute instance-groups managed create --help", one can use 'size' option to specify minimum/initial number of VMs in the auto-scaling group.

--size=SIZE
The initial number of instances you want in this group.

I've ran this command many times over last couple of days, and each time, specifying value of '1', results in '2' instances being created.

Example of such a command is as follows -

gcloud compute instance-groups managed create sc-demo-2016-squid-us-central1-a --size 1 --template sc-demo-2016-squid-template

Is this a bug or behavior that I don't understand?

Check with Google!

History

#1 Updated by Neha Sharma almost 4 years ago

  • Assignee set to Neha Sharma

#2 Updated by Neha Sharma almost 4 years ago

As per email exchange with Solomon, this happened because

I did not specify -min-num-replicas option when configuring auto scaling group and max-num-replicas was set to 5.
In this case, autoscaler decides the min replica number, based on value of max-num-replicas and ignores the value of "size" used when creating the auto scaling group

gcloud compute instance-groups managed set-autoscaling sc-demo-2016-squid-us-central1-a --max-num-replicas 5 --target-load-balancing-utilization 1.0 --cool-down-period 260

He will file a bug report. In the meantime, command to use would be something like

gcloud compute instance-groups managed set-autoscaling sc-demo-2016-squid-us-central1-a --min-num-replicas 1 --max-num-replicas 5 --target-load-balancing-utilization 1.0 --cool-down-period 260

#3 Updated by Steven Timm almost 4 years ago

  • Due date set to 11/07/2016
  • Status changed from New to Resolved
  • % Done changed from 0 to 100
  • Estimated time set to 2.00 h

This works when we use the --min-num-replicas option. We can do what we need to do. Marking this resolved.

#4 Updated by Steven Timm almost 4 years ago

  • Status changed from Resolved to Closed


Also available in: Atom PDF