It’s a tale as old as time: An enterprise recognizes its need for cloud transformation, realizes invaluable operational advantages by implementing Kubernetes clusters and … drops its collective jaw when cloud bills start coming due. In the old days, virtual machines (VMs) were manually provisioned and unused space was wasted; now, Kubernetes schedules workloads to share those VMs. But even though sharing VMs brings some cost benefits immediately, Kubernetes and its scheduler remain complex to navigate efficiently. Many, if not most, organizations don’t possess the right expertise or strategies to optimize their Kubernetes costs out of the gate.

Google Cloud’s recently released State of Kubernetes Cost Optimization report taps real-world data to outline the current outlook and opportunities for organizations seeking to improve the cost efficiency and reliability of their Kubernetes deployments. By looking at the numbers around how the most cost-efficient organizations are performing, the report identifies key findings and approaches that those eager to get their Kubernetes costs under control would do well to emulate.

The Google Cloud report is worth a read in its entirety, but here are five takeaways from the report that shouldn’t be ignored:

1. Right-size your resource requests.

Setting accurate and appropriate resource requests is critical to Kubernetes cost efficiency and reliability. However, the Google Cloud report underscores the difficulty many organizations face in trying to strike the right balance. It’s a Goldilocks challenge. Under-provisioned your Kubernetes workloads with undersized resource requests? You risk application disruptions and reliability issues (as Kubernetes terminates pods that don’t have the resources available to operate). Over-provisioned Kubernetes workloads, as most organizations do in order to keep their applications performing smoothly? Now you’re wasting resources and incurring massive unnecessary costs.

With the right strategy, this challenge can pivot into a tremendous opportunity for cost optimization. Organizations that empower their technical teams with granular visibility into Kubernetes spending—including tagging cost responsibilities down to the team and service levels—have the clarity required to right-size available resources. Backed by strategies that allow teams to recognize resource overruns in real time, these organizations make continuous efforts to accurately meet container and node needs with cost-effective configurations. Adopting similar strategies, with visibility and alerting driving recommended actions, allows organizations that are currently struggling to successfully align their Kubernetes spending with their actual needs.

2. Choose the right workload types for cost-effective reliability and performance.

Selecting the right workload types to balance the reliability and performance of Kubernetes clusters with efficient spending is another key challenge for organizations. The Google Cloud report reveals that unintentional usage of some specific workload types is at the root of many performance and reliability struggles. For this reason, thoughtful deployment of BestEffort Pods and memory under-provisioned Burstable Pods is a key best practice for more stable Kubernetes cluster operations.

3. Balance costs while making the experiences of end users a top priority.

The report highlights the struggle to prioritize both user experience and cost optimization, reducing spending without letting users feel the pinch. For example, using numerous BestEffort Pods or memory under-provisioned Burstable Pods in a cluster often correlates with lower cluster bin packing. While platform admins may, therefore, see an opportunity to downscale those nodes to save on costs, doing so frequently leads to unforeseen Pod terminations and application disruptions. Leveraging enhanced Kubernetes visibility to foresee the impact of changes—with a focus on prioritizing the user experience—can make a big difference by ensuring that cost controls are harmless to essential user-facing functions.

4. Demand-based downscaling is a highly effective technique.

The Google Cloud report shines a spotlight on demand-based downscaling, detailing how organizations with elite cost optimization achievements have become highly efficient in leveraging Cluster Autoscaler, Horizontal Pod Autoscaler, and Vertical Pod Autoscaler functionality. The most efficient organizations demonstrate expertise in realizing off-peak spending reduction by scaling down clusters using these tools. Additional techniques, such as automated scheduling—capable of spinning clusters and workloads up and down to meet demand—offer even more cost efficiency. Those looking to implement more cost-effective Kubernetes strategies should invest their efforts in well-configured autoscaling functionality and join the ranks of top performers getting the most for their Kubernetes dollars.

5. Put cloud discounts to work.

Finally, enterprises demonstrating high-level Kubernetes cost optimization make the most of their opportunities for cloud discounts. That means leveraging Spot VMs, Reserved Instances, and other available-for-the-taking discount offers. Also worth noting: top performers tend to employ dedicated cost optimization teams, use larger clusters, and have the ability to forecast costs across long-term commitments.

Incorporating Kubernetes Cost Optimization Best Practices

The Google Cloud report provides a window into the techniques used within highly efficient Kubernetes deployments, outlining several current strategies that can be invaluable for organizations still struggling along their cost optimization journeys. Pursuing efficiency while being more mindful of resource requests, workload types, user experiences, demand-based downscaling and cloud discounts can start putting your organization on the same page as top Kubernetes optimization performers.


To hear more about cloud-native topics, join the Cloud Native Computing Foundation and the cloud-native community at KubeCon+CloudNativeCon North America 2023 – November 6-9, 2023.