Spot by NetApp’s Ocean continually optimizes a Kubernetes cluster’s data plane. When Ocean identifies nodes that aren’t being fully utilized, it simulates various bin packing scenarios. Once a more efficient layout is identified, Ocean reschedules pods, and then gracefully terminates the underutilized nodes. Ocean’s continuous optimization of cluster infrastructure saves your organization money and is better for planet Earth!
Ocean’s Virtual Node Groups (VNGs) provide a layer of abstraction that enables efficient management of different types of workloads in the same cluster. In the quest for optimal resource usage, Ocean will scale down each VNG’s nodes to the minimum number and size needed for its workloads. Endeavoring to scale to zero is the optimal, and therefore best behavior, right? It turns out there are cases when having a fixed minimum number of nodes can benefit the cluster. We are excited to share details about a new option to set a minimum number of nodes per VNG. When set, this option ensures Ocean doesn’t scale below this threshold, even if it normally would. The minimum nodes per VNG setting is now available for Kubernetes clusters running at AWS and GCP.
Setting the minimum number of nodes to a value greater than one can help ensure application availability. Imagine that all your deployment’s pods are running on a highly utilized single node that disappears unexpectedly. Your application will be unavailable until a replacement node is provisioned. Based on your knowledge of workload requirements, you can ensure a suitable minimum number of nodes is available. These nodes will accept the pending pods and reduce the negative impact of this event. Setting a minimum number of nodes can also help ensure the natural spread of newly deployed workloads. It does this by giving the Kubernetes scheduler more nodes to consider when deciding where each pod should be scheduled. Please note: this is a way to apply a soft requirement for pod spread. If you have hard requirements related to pod spread, then make use of taints, tolerations, or take a look at pod topology spread constraints.
Ocean managed clusters have a feature called headroom. Headroom is a buffer of spare capacity that is maintained to absorb spikes in resource requests. Headroom can be configured automatically as a percentage of currently used resources. In addition, it can be configured manually by setting specific values for the CPU, memory, or GPU capacity desired. You can also enable both automatic and manual configuration settings. When specifying manual headroom, Ocean will try to keep all spare capacity units on the same node. This is optimal as far as reducing the number of running nodes. Until now there was no way to ensure that the requested manual headroom units would be spread across multiple nodes.
When you set a minimum number of nodes for a VNG, Ocean will immediately scale new nodes to meet that minimum.
The Parameter name:
minInstanceCount is used to specify a minimum number of nodes for a VNG. Set it to an integer value of 0 or more.
This new setting is available as part of the
resourceLimits under a
launchSpec. You can set it when creating or updating an Ocean VNG.
Setting a value for
min_instance_count is supported in version 1.60.0 or greater of both the AWS and GKE spotinst Terraform providers.
This setting joins
max_instance_count in the
resource_limits configuration block.
max_instance_count = 20
min_instance_count = 3
The minimum instance count for a specific VNG can be configured from the Spot web UI. You’ll find this setting, labeled “Minimum Nodes”, by navigating into the VNG details and looking under “Advanced.”
Using the new minimum nodes per VNG setting provides you with additional control over how Spot Ocean manages the nodes that make up your Kubernetes cluster’s data plane. Please reach out to any of your contacts at Spot by NetApp or contact us with questions. We are happy to help!