From 82bd538421dab4ee63749a13f5fe2c6a5fb5b560 Mon Sep 17 00:00:00 2001 From: Clayton Coleman Date: Tue, 15 Jan 2019 13:24:17 -0500 Subject: [PATCH] aws: Double the master instance size We were seeing frequent long requests from etcd. After increasing CPU (2 -> 4 cores) those pauses dropped significantly. Increase the limit until the rebase lands and we can deliver the CPU perf improvements to the control plane. Make a set of changes to connect machine set size to the values passed as input. Update the docs. --- data/data/aws/variables-aws.tf | 2 +- docs/user/aws/limits.md | 10 ++++++++-- pkg/asset/machines/master.go | 1 + pkg/asset/machines/worker.go | 5 ++--- 4 files changed, 12 insertions(+), 6 deletions(-) diff --git a/data/data/aws/variables-aws.tf b/data/data/aws/variables-aws.tf index a6a602d2d02..02f4e51f1fe 100644 --- a/data/data/aws/variables-aws.tf +++ b/data/data/aws/variables-aws.tf @@ -12,7 +12,7 @@ variable "aws_master_ec2_type" { description = "Instance size for the master node(s). Example: `m4.large`." # FIXME: get this wired up to the machine default - default = "m4.large" + default = "m4.xlarge" } variable "aws_ec2_ami_override" { diff --git a/docs/user/aws/limits.md b/docs/user/aws/limits.md index 3dffd3ab9aa..82b50345fed 100644 --- a/docs/user/aws/limits.md +++ b/docs/user/aws/limits.md @@ -58,8 +58,14 @@ to be created. ## Instance Limits -By default, a cluster will create 6 nodes (3 masters and 3 workers). Currently, these are m4.large and within a new -account's default limit. If you intend to start with a higher number of workers, enable autoscaling and large workloads +By default, a cluster will create: + +* One m4.large bootstrap machine (removed after install) +* Three m4.xlarge master nodes. +* Three m4.large worker nodes. + +Currently, these instance type counts are within a new account's default limit. +If you intend to start with a higher number of workers, enable autoscaling and large workloads or a different instance type, please ensure you have the necessary remaining instance count within the instance type's limit to satisfy the need. If not, please ask AWS to increase the limit via a support case. diff --git a/pkg/asset/machines/master.go b/pkg/asset/machines/master.go index 26f154bef56..2c782ac12a6 100644 --- a/pkg/asset/machines/master.go +++ b/pkg/asset/machines/master.go @@ -67,6 +67,7 @@ func (m *Master) Generate(dependencies asset.Parents) error { switch ic.Platform.Name() { case awstypes.Name: mpool := defaultAWSMachinePoolPlatform() + mpool.InstanceType = "m4.xlarge" mpool.Set(ic.Platform.AWS.DefaultMachinePlatform) mpool.Set(pool.Platform.AWS) if len(mpool.Zones) == 0 { diff --git a/pkg/asset/machines/worker.go b/pkg/asset/machines/worker.go index 67d339bb7e0..71bd7434d36 100644 --- a/pkg/asset/machines/worker.go +++ b/pkg/asset/machines/worker.go @@ -26,9 +26,7 @@ import ( ) func defaultAWSMachinePoolPlatform() awstypes.MachinePool { - return awstypes.MachinePool{ - InstanceType: "m4.large", - } + return awstypes.MachinePool{} } func defaultLibvirtMachinePoolPlatform() libvirttypes.MachinePool { @@ -94,6 +92,7 @@ func (w *Worker) Generate(dependencies asset.Parents) error { switch ic.Platform.Name() { case awstypes.Name: mpool := defaultAWSMachinePoolPlatform() + mpool.InstanceType = "m4.large" mpool.Set(ic.Platform.AWS.DefaultMachinePlatform) mpool.Set(pool.Platform.AWS) if len(mpool.Zones) == 0 {