Files
nexus/sreweekly/articles/457/01-preventing-out-of-memory-oom-kills-in-kubernetes-tips-for-optimizing-c.html
2026-09-12 17:23:01 +08:00

1 line
103 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html><html data-dpl-id="dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E" lang="en" class="dark"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="/_next/static/immutable/chunks/3vdpttbswk5bm.css" data-precedence="next"/><link rel="stylesheet" href="/_next/static/immutable/chunks/3trq96g6e7_2e.css" data-precedence="next"/><link rel="preload" as="script" fetchPriority="low" href="/_next/static/immutable/chunks/17tuxysuvqwd2.js"/><script src="/_next/static/immutable/chunks/0a9iqm8cm672n.js" async=""></script><script src="/_next/static/immutable/chunks/3qh1od292ulre.js" async=""></script><script src="/_next/static/immutable/chunks/2iuwuc1nj_nup.js" async=""></script><script src="/_next/static/immutable/chunks/turbopack-3oon2pgk340gb.js" async=""></script><script src="/_next/static/immutable/chunks/011me_93942kq.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/1c_nr-0i0gjnt.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/3lgnztd7blcu2.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/17dj4bkkdjper.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/0vbcyr25-edwj.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/0qn98tgsfm7pc.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/2-s-9-xpk6j_j.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/0ojqgjv--k_a7.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/3cxalgnb-xm18.js" async="" crossorigin=""></script><script src="/_next/static/immutable/chunks/3ithhqp6kca4w.js" async="" crossorigin=""></script><meta name="theme-color" content="#020817"/><meta name="next-size-adjust" content=""/><title>Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management | Causely</title><meta name="description" content="Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernet"/><link rel="manifest" href="/manifest.json"/><meta property="og:title" content="Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management"/><meta property="og:description" content="Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernet"/><meta property="og:image" content="https://storage.ghost.io/c/f4/30/f4302d25-b539-4f59-b4cb-e3882f8f5026/content/images/wp-content/uploads/2024/08/preventing-oom-kills-1.png"/><meta property="og:image:width" content="1200"/><meta property="og:image:height" content="630"/><meta property="og:type" content="article"/><meta property="article:published_time" content="2024-08-28T20:24:25.000+00:00"/><meta property="article:author" content="Causely"/><meta name="twitter:card" content="summary_large_image"/><meta name="twitter:title" content="Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management"/><meta name="twitter:description" content="Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernet"/><meta name="twitter:image" content="https://storage.ghost.io/c/f4/30/f4302d25-b539-4f59-b4cb-e3882f8f5026/content/images/wp-content/uploads/2024/08/preventing-oom-kills-1.png"/><link rel="icon" href="/favicon.ico" sizes="any"/><link rel="apple-touch-icon" href="/apple-touch-icon.png" sizes="180x180"/><script type="application/ld+json">[{"@context":"https://schema.org","@id":"https://www.causely.ai/#organization","@type":"Organization","name":"Causely","logo":"https://www.causely.ai/images/causely-logo-white.svg","url":"https://www.causely.ai/","sameAs":["https://www.linkedin.com/company/causely-ai/","https://twitter.com/Causelyai","https://www.youtube.com/@Causely-ai"],"description":"Causely pinpoints the root cause of errors so that you can consistently meet reliability expectations of application users in complex, cloud native environments.","contactPoint":{"@type":"ContactPoint","contactType":"Business","url":"https://www.causely.ai/try"}},{"@context":"https://schema.org","@type":"WebSite","url":"https://www.causely.ai/","name":"Causely","description":"Causely pinpoints the root cause of errors so that you can consistently meet reliability expectations of application users in complex, cloud native environments.","publisher":{"@id":"https://www.causely.ai/#organization"}},{"@context":"https://schema.org","@type":"Service","serviceType":"Autonomous Service Reliability Platform","provider":{"@id":"https://www.causely.ai/#organization"},"description":"Causely's Causal Reasoning Platform continuously analyzes observed anomalies to automatically pinpoint root causes and trigger immediate remediation actions.","areaServed":{"@type":"AdministrativeArea","name":"Worldwide"}}]</script><script src="/_next/static/immutable/chunks/0c0hxoamwjsbw.js" noModule=""></script></head><body class="inter_4259f421-module__8cy6qW__variable dm_mono_d7d5bd4-module__m3ieCa__variable generalsans_a3c20b4-module__cx286q__variable flex min-h-screen flex-col"><div hidden=""><!--$--><!--/$--></div><div id="smooth-wrapper"><div id="smooth-content"><script>((a,b,c,d,e,f,g,h)=>{let i=document.documentElement,j=["light","dark"];function k(b){var c;(Array.isArray(a)?a:[a]).forEach(a=>{let c="class"===a,d=c&&f?e.map(a=>f[a]||a):e;c?(i.classList.remove(...d),i.classList.add(b)):i.setAttribute(a,b)}),c=b,h&&j.includes(c)&&(i.style.colorScheme=c)}if(d)k(d);else try{let a=localStorage.getItem(b)||c,d=g&&"system"===a?window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":a;k(d)}catch(a){}})("class","theme","dark",null,["light","dark"],null,false,true)</script><div class="relative flex min-h-screen flex-col bg-main-background"><main class="flex-1 bg-main-background"><div class="w-full bg-[linear-gradient(to_right,#07bc85_0%,#8dfcdb_90%,#8dfcdb_100%)] relative overflow-hidden group"><div class="max-w-7xl mx-auto relative z-10"><a class="flex items-center justify-center py-2 px-4 gap-3 text-xs md:text-sm font-semibold transition-all duration-300" href="/product/benchmark"><span class="flex items-center gap-2 min-w-0 overflow-hidden"><span class="bg-black/10 text-black px-2.5 py-0.5 rounded-full text-[10px] uppercase tracking-widest font-black shrink-0 border border-black/10">New</span><span class="text-black truncate">72 experiments on the latest agents</span></span><span class="flex items-center gap-1.5 text-black/80 group-hover:text-black group-hover:gap-2.5 transition-all shrink-0"><span class="underline decoration-black/20 underline-offset-4 font-bold">Read the study</span><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-arrow-right w-4 h-4"><path d="M5 12h14"></path><path d="m12 5 7 7-7 7"></path></svg></span></a></div></div><header class="sticky top-0 z-[60] w-full" id="site-header"><div class="mx-auto relative z-[60] px-6 py-5 md:px-[48px] xl:px-14 md:py-5 3xl:px-0 3xl:max-w-[1560px]"><div class="bg-navbar-bg rounded-[64px] pl-[13px] pr-2 py-2 md:pl-[23px] md:pr-4 md:py-4 flex items-center justify-between w-full relative z-[60]"><a class="flex items-center" href="/"><img alt="Causely" width="134" height="47" decoding="async" data-nimg="1" class="h-[32px] w-[91.429px] md:h-[47px] md:w-[134px]" style="color:transparent" src="/images/causely-logo-white.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></a><button class="md:hidden bg-causely-green-300 rounded-full w-[40px] h-[40px] flex items-center justify-center hover:bg-causely-green-300/80 transition-colors duration-300 relative z-[61]" aria-label="Open menu"><img alt="Open menu" loading="lazy" width="16" height="16" decoding="async" data-nimg="1" class="w-4 h-4 transition-transform duration-300" style="color:transparent" src="/images/icons/dotted-cross.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></button><div class="hidden md:flex items-center gap-3"><div class="flex items-center gap-4"><div class="relative"><button class="px-[10px] py-[8px] font-sans text-[14px] 3xl:text-[16px] font-normal leading-[20px] transition-colors hover:text-causely-green relative flex items-center gap-1 text-white">Product<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-down w-3 h-3 transition-transform duration-200"><path d="m6 9 6 6 6-6"></path></svg></button></div><a target="_blank" rel="noopener noreferrer" class="px-[10px] py-[8px] font-sans text-[14px] 3xl:text-[16px] font-normal leading-[20px] transition-colors hover:text-causely-green relative text-white" href="https://docs.causely.ai">Docs</a><a class="px-[10px] py-[8px] font-sans text-[14px] 3xl:text-[16px] font-normal leading-[20px] transition-colors hover:text-causely-green relative text-white" href="/pricing">Pricing</a><a class="px-[10px] py-[8px] font-sans text-[14px] 3xl:text-[16px] font-normal leading-[20px] transition-colors hover:text-causely-green relative text-white" href="/security">Security</a><a class="px-[10px] py-[8px] font-sans text-[14px] 3xl:text-[16px] font-normal leading-[20px] transition-colors hover:text-causely-green relative text-causely-green" href="/blog">Blog<span class="absolute bottom-0 left-[10px] right-[10px] h-[2px] bg-causely-green"></span></a></div><a class="flex items-center group relative overflow-hidden rounded-full" href="https://auth.causely.app/oauth/account/sign-up"><div class="absolute right-0 top-1/2 -translate-y-1/2 bg-causely-green-300 rounded-full w-[40px] h-[40px] md:group-hover:w-full md:group-hover:h-full md:group-hover:top-0 md:group-hover:right-0 md:group-hover:translate-y-0 transition-all duration-500 ease-out z-0"></div><div class="flex items-center mr-[-6px] px-[23px] py-[12px] rounded-full relative z-10"><span class="relative font-general-sans font-medium text-[16px] leading-[1.001]"><span class="bg-gradient-to-r from-causely-green to-causely-green-300 bg-clip-text text-transparent opacity-100 md:group-hover:opacity-0 transition-opacity duration-300">Try now</span><span class="absolute inset-0 text-[#020817] opacity-0 md:group-hover:opacity-100 transition-opacity duration-300">Try now</span></span></div><div class="p-[12px] w-[40px] h-[40px] flex items-center justify-center relative z-10"><img alt="Arrow" loading="lazy" width="16" height="16" decoding="async" data-nimg="1" class="w-[16px] h-[16px]" style="color:transparent" src="/images/icons/dotted-arrow.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></a></div></div></div><div class="fixed inset-0 z-[50] h-screen backdrop-blur-[6px] bg-main-background/80 md:hidden opacity-0 translate-y-[-20px] pointer-events-none" style="touch-action:auto"><div class="flex flex-col px-6 py-5 h-full"><div class="h-[76px]"></div><div class="flex flex-col gap-3 rounded-xl w-full py-2"><div class="flex flex-col gap-3"><div class="flex flex-col gap-3"><div class="flex items-center justify-between"><a class="px-[10px] py-2 font-inter text-[14px] leading-[14px] text-white font-normal" href="/product">Product</a><button class="p-2 text-white/60 hover:text-white transition-colors" aria-label="Toggle product menu"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevron-down w-4 h-4 transition-transform duration-200"><path d="m6 9 6 6 6-6"></path></svg></button></div><div class="w-full h-px bg-grey-500"></div></div><div class="flex flex-col gap-3"><a target="_blank" rel="noopener noreferrer" class="px-[10px] py-2 font-inter text-[14px] leading-[14px] text-white font-normal" href="https://docs.causely.ai">Docs</a><div class="w-full h-px bg-grey-500"></div></div><div class="flex flex-col gap-3"><a class="px-[10px] py-2 font-inter text-[14px] leading-[14px] text-white font-normal" href="/pricing">Pricing</a><div class="w-full h-px bg-grey-500"></div></div><div class="flex flex-col gap-3"><a class="px-[10px] py-2 font-inter text-[14px] leading-[14px] text-white font-normal" href="/security">Security</a><div class="w-full h-px bg-grey-500"></div></div><div class="flex flex-col gap-3"><a class="px-[10px] py-2 font-inter text-[14px] leading-[14px] text-causely-green font-medium" href="/blog">Blog</a></div></div><div class="w-full h-px bg-grey-500"></div><div class="flex flex-col gap-4 items-start"><a class="flex items-center group relative overflow-hidden rounded-full" href="https://auth.causely.app/oauth/account/sign-up"><div class="absolute right-0 top-1/2 -translate-y-1/2 bg-causely-green-300 rounded-full w-[40px] h-[40px] md:group-hover:w-full md:group-hover:h-full md:group-hover:top-0 md:group-hover:right-0 md:group-hover:translate-y-0 transition-all duration-500 ease-out z-0"></div><div class="flex items-center mr-[-6px] px-[23px] rounded-full relative z-10 pl-0 pr-[23px] py-[12px]"><span class="relative font-general-sans font-medium text-[16px] leading-[1.001]"><span class="bg-gradient-to-r from-causely-green to-causely-green-300 bg-clip-text text-transparent opacity-100 md:group-hover:opacity-0 transition-opacity duration-300">Try now</span><span class="absolute inset-0 text-[#020817] opacity-0 md:group-hover:opacity-100 transition-opacity duration-300">Try now</span></span></div><div class="p-[12px] w-[40px] h-[40px] flex items-center justify-center relative z-10"><img alt="Arrow" loading="lazy" width="16" height="16" decoding="async" data-nimg="1" class="w-[16px] h-[16px]" style="color:transparent" src="/images/icons/dotted-arrow.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></a><a href="https://auth.causely.app/oauth/account/login" target="_blank" rel="noopener noreferrer" class="justify-center whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group flex items-center relative"><div class="rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden border border-white-custom group-hover:border-causely-green"><span class="font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-white-custom group-hover:text-causely-green">Sign in</span></div></a></div></div></div></div></header><div><article class="container max-w-4xl py-12"><div class="mb-8"><h1 class="text-4xl font-bold mb-4">Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management</h1><div class="flex items-center mb-8"><div class="flex -space-x-2 mr-3"><img alt="Causely" loading="lazy" width="40" height="40" decoding="async" data-nimg="1" class="rounded-full ring-2 ring-background" style="color:transparent" srcSet="/_next/image?url=%2Fimages%2Fnewsroom%2FCauselyIcon.png&amp;w=48&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 1x, /_next/image?url=%2Fimages%2Fnewsroom%2FCauselyIcon.png&amp;w=96&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 2x" src="/_next/image?url=%2Fimages%2Fnewsroom%2FCauselyIcon.png&amp;w=96&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div><div><p class="font-medium">Causely</p><p class="text-sm text-muted-foreground">August 28, 2024</p></div></div></div><div class="relative aspect-video mb-12"><img alt="Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management" loading="lazy" decoding="async" data-nimg="fill" class="object-cover rounded-lg" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" sizes="100vw" srcSet="/_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=640&amp;q=75 640w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=750&amp;q=75 750w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=828&amp;q=75 828w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=1080&amp;q=75 1080w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=1200&amp;q=75 1200w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=1920&amp;q=75 1920w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=2048&amp;q=75 2048w, /_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=3840&amp;q=75 3840w" src="/_next/image?url=https%3A%2F%2Fstorage.ghost.io%2Fc%2Ff4%2F30%2Ff4302d25-b539-4f59-b4cb-e3882f8f5026%2Fcontent%2Fimages%2Fwp-content%2Fuploads%2F2024%2F08%2Fpreventing-oom-kills-1.png&amp;w=3840&amp;q=75"/></div><div class="prose prose-invert prose-dark max-w-none"><p>Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernetes kernel’s OOM killer disrupts application stability and can affect application availability and the health of your overall environment.</p><p>In this post, we’ll explore the reasons that OOM kills can occur and provide tactics to combat and prevent them.</p><p>Before diving in, it’s worth noting that OOM kills represent one symptom that can have a variety of root causes. It’s important for organizations to implement a system that solves the root cause analysis problem with speed and accuracy, allowing reliability engineering teams to respond rapidly, and to potentially prevent these occurrences in the first place.</p><h2 id="deep-dive-into-an-oom-kill">Deep dive into an OOM kill</h2><p>An Out-Of-Memory (OOM) kill in <a href="https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io">Kubernetes</a> occurs when a container exceeds its memory limit, causing the Kubernetes kernel’s OOM killer to terminate the container. This impacts application stability and requires immediate attention.</p><p>Several factors can trigger OOM kills in your Kubernetes environment, including:</p><ul><li><strong>Memory limits exceeded:</strong> This is the most common culprit. If a container consistently pushes past its designated memory ceiling, the OOM killer steps in to prevent a system-wide meltdown.</li><li><strong>Memory leaks:</strong> Applications can develop memory leaks over time, where they allocate memory but fail to release it properly. This hidden, unexpected growth eventually leads to OOM kills.</li><li><strong>Resource overcommitment:</strong> Co-locating too many resource-hungry pods onto a single node can deplete available memory. When the combined memory usage exceeds capacity, the OOM killer springs into action.</li><li><strong>Bursting workloads:</strong> Applications with spiky workloads can experience sudden memory surges that breach their limits, triggering OOM kills.</li></ul><p>As an example, a web server that experiences a memory leak code bug may gradually consume more and more memory until the OOM killer intervenes to prevent a crash.</p><p>Another case could be when a Kubernetes cluster over-commits resources by scheduling too many pods on a single node. The OOM killer may need to step in to free up memory and ensure system stability.</p><h2 id="the-devastating-effects-of-oom-kills-why-they-matter">The devastating effects of OOM kills: Why they matter</h2><p>OOM kills aren’t normally occurring events. They can trigger a cascade of negative consequences for your applications and the overall health of the cluster, such as:</p><ul><li><strong>Application downtime:</strong> When a container is OOM-killed, it abruptly terminates, causing immediate application downtime. Users may experience service disruptions and outages.</li><li><strong>Data loss:</strong> Applications that rely on in-memory data or stateful sessions risk losing critical information during an OOM kill.</li><li><strong>Performance degradation:</strong> Frequent OOM kills force containers to restart repeatedly. This constant churn degrades overall application performance and user experience.</li><li><strong>Service disruption:</strong> Applications often interact with each other. An OOM kill in one container can disrupt inter-service communication, causing cascading failures and broader service outages.</li></ul><p>If a container running a critical database service experiences an OOM kill, it could result in data loss and corruption. This leads to service disruptions for other containers that rely on the database for information, causing cascading failures across the entire application ecosystem.</p><h2 id="combating-oom-kills">Combating OOM kills</h2><p>There are a few different tactics to combat OOM kills in attempt to operate a memory-efficient Kubernetes environment.</p><h3 id="set-appropriate-resource-requests-and-limits">Set appropriate resource requests and limits</h3><p>For example, you can set a memory request of 200Mi and a memory limit of 300Mi for a particular container in your Kubernetes deployment. Requests ensure the container gets at least 200Mi of memory, while limits cap it at 300Mi to prevent excessive consumption.</p><pre class="prism-code language-json" style="color:#d6deeb;background-color:#011627;padding:1rem;border-radius:0.5rem"><div class="token-line" style="color:#d6deeb"><span class="token plain">resources</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> requests</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> memory</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;200Mi&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> limits</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> memory</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;300Mi&quot;</span></div></pre><p>While this may mitigate potential memory use issues, it is a very manual process and does not deal at all with the dynamic nature of what we can achieve with Kubernetes. It also doesn’t solve the source issue, which may be a code-level problem triggering memory leaks or failed GC processes.</p><h3 id="transition-to-autoscaling">Transition to autoscaling</h3><p>Leveraging <a href="https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io">autoscaling</a> capabilities is a core dynamic option for resource allocation. There are two autoscaling methods:</p><ul><li><strong>Vertical Pod Autoscaling (VPA):</strong> <a href="https://kubernetes.io/docs/concepts/workloads/autoscaling/?ref=causely-blog.ghost.io" rel="noopener">VPA</a> dynamically adjusts resource limits based on real-time memory usage patterns. This ensures containers have enough memory to function but avoids over-provisioning.</li><li><strong>Horizontal Pod Autoscaling (HPA):</strong> <a href="https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/?ref=causely-blog.ghost.io" rel="noopener">HPA</a> scales the number of pods running your application up or down based on memory utilization. This distributes memory usage across multiple pods, preventing any single pod from exceeding its limit. The following HPA configuration shows an example of scaling based on memory usage:</li></ul><pre class="prism-code language-json" style="color:#d6deeb;background-color:#011627;padding:1rem;border-radius:0.5rem"><div class="token-line" style="color:#d6deeb"><span class="token plain">apiVersion</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> autoscaling/v2beta2</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">kind</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> HorizontalPodAutoscaler</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">metadata</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> name</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> my-app-hpa</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">spec</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> scaleTargetRef</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> apiVersion</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> apps/v1</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> kind</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> Deployment</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> name</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> my-app</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> minReplicas</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(247, 140, 108)">2</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> maxReplicas</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(247, 140, 108)">10</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> metrics</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> - type</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> Resource</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> resource</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> name</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> memory</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> target</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> type</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> Utilization</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> averageUtilization</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(247, 140, 108)">80</span></div></pre><h3 id="monitor-memory-usage">Monitor memory usage</h3><p>Proactive monitoring is key. For instance, you can configure <a href="https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io">Prometheus</a> to scrape memory metrics from your Kubernetes pods every 15 seconds and set up <a href="https://grafana.com/?ref=causely-blog.ghost.io" rel="noopener">Grafana</a> dashboards to visualize memory usage trends over time. Additionally, you can create alerts in Prometheus to trigger notifications when memory usage exceeds a certain threshold.</p><h3 id="optimize-application-memory-usage">Optimize application memory usage</h3><p>Don’t underestimate the power of code optimization. Address memory leaks within your applications and implement memory-efficient data structures to minimize memory consumption.</p><h3 id="pool-disruption-budgets-pdb">Pool disruption budgets (PDB)</h3><p>When deploying updates, <a href="https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io">PDBs</a> ensure a minimum number of pods remain available, even during rollouts. This mitigates the risk of widespread OOM kills during deployments. Here is a PDB configuration example that helps ensure minimum pod availability.</p><pre class="prism-code language-json" style="color:#d6deeb;background-color:#011627;padding:1rem;border-radius:0.5rem"><div class="token-line" style="color:#d6deeb"><span class="token plain">apiVersion</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> policy/v1</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">kind</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> PodDisruptionBudget</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">metadata</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> name</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> my-app-pdb</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">spec</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> minAvailable</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(247, 140, 108)">80</span><span class="token plain">%</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> selector</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> matchLabels</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> app</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> my-app</span></div></pre><h3 id="manage-node-resources">Manage node resources</h3><p>You can apply a node selector to ensure that a memory-intensive pod is only scheduled on nodes with a minimum of 8GB of memory. Additionally, you can use taints and tolerations to dedicate specific nodes with high memory capacity for memory-hungry applications, preventing OOM kills due to resource constraints.</p><pre class="prism-code language-json" style="color:#d6deeb;background-color:#011627;padding:1rem;border-radius:0.5rem"><div class="token-line" style="color:#d6deeb"><span class="token plain">nodeSelector</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> disktype</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> ssd</span></div><div class="token-line" style="color:#d6deeb"><span class="token plain">tolerations</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> - key</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;key&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> operator</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;Equal&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> value</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;value&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> effect</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;NoSchedule&quot;</span></div></pre><h3 id="use-qos-classes">Use QoS classes</h3><p>Kubernetes offers Quality of Service (<a href="https://kubernetes.io/docs/concepts/workloads/pods/pod-qos/?ref=causely-blog.ghost.io" rel="noopener">QoS</a>) classes that prioritize resource allocation for critical applications. Assign the highest QoS class to applications that can least tolerate OOM kills. Here is a sample resource configuration with QoS parameters:</p><pre class="prism-code language-json" style="color:#d6deeb;background-color:#011627;padding:1rem;border-radius:0.5rem"><div class="token-line" style="color:#d6deeb"><span class="token plain">resources</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> requests</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> memory</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;1Gi&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> cpu</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;500m&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> limits</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> memory</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;1Gi&quot;</span><span class="token plain"></span></div><div class="token-line" style="color:#d6deeb"><span class="token plain"> cpu</span><span class="token operator" style="color:rgb(127, 219, 202)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(173, 219, 103)">&quot;500m&quot;</span></div></pre><p>These are a few potential strategies to help prevent OOM kills. The challenge comes with the frequency with which they can occur, and the risk to your applications when they happen.</p><p>As you can imagine, it’s not possible to manually manage resource utilization, and guarantee the stability and performance of your containerized applications within your Kubernetes environment.</p><h2 id="manual-thresholds-rigidity-and-risk">Manual thresholds = Rigidity and risk</h2><p>These techniques can help reduce the risk of OOM kills. The issue is not entirely solved though. By setting manual thresholds and limits, you’re removing many of the dynamic advantages of Kubernetes.</p><p>A more ideal way to solve the OOM kill problem is to use adaptive, dynamic resource allocation. Even if you get resource allocation right on initial deployment, there are many factors that change that affect how your application consumes resources. There is also a risk because application and resource issues don’t just affect one pod, or one container. Resource issues can reach every part of the cluster and degrade the other running applications and services.</p><h2 id="which-strategy-works-best-to-prevent-oom-kills">Which strategy works best to prevent OOM kills?</h2><p>Vertical Pod Autoscaling (VPA) and Horizontal Pod Autoscaling (HPA) are common strategies used to manage resource limits in Kubernetes containers. VPA adjusts resource limits based on real-time memory usage patterns, while HPA scales pods based on memory utilization.</p><p>Monitoring with tools like Prometheus may help with the troubleshooting of memory usage trends. Optimizing application memory usage is no easy feat because it’s especially challenging to identify whether it is infrastructure or code causing the problem.</p><p>Pod Disruption Budgets (PDB) may help ensure a minimum number of pods remain available during deployments, while node resources can be managed using node selectors and taints. Quality of Service (QoS) classes prioritize resource allocation for critical applications.</p><p>One thing is certain: OOM kills are a common and costly challenge to manage using traditional monitoring tools and methods.</p><p>At <a href="https://www.causely.ai/?ref=causely-blog.ghost.io">Causely</a>, we’re focused on applying causal reasoning software to help organizations keep applications healthy and resilient. By automating root cause analysis, issues like OOM kills can be resolved in seconds, and unintended consequences of new releases or application changes can be avoided.</p><h2 id="related-resources">Related resources</h2><ul><li><a href="https://www.causely.ai/blog/understanding-kubernetes-readiness-probe-to-ensure-your-applications-availability/?ref=causely-blog.ghost.io">Read the blog</a>: Understanding the Kubernetes Readiness Probe: A Tool for Application Health</li><li><a href="https://www.causely.ai/blog/bridging-the-gap-between-observability-and-automation-with-causal-reasoning/?ref=causely-blog.ghost.io">Read the blog</a>: Bridging the gap between observability and automation with causal reasoning</li></ul><p>Watch our webinar on Causal AI and why DevOps teams need it:</p><figure class="kg-card kg-embed-card"><div class="my-6 relative w-full aspect-video rounded-lg overflow-hidden"><iframe src="https://www.youtube.com/embed/pSl4pGCczOU?feature=oembed" title="What is Causal AI and why do DevOps teams need it?" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowFullScreen="" class="absolute inset-0 w-full h-full" referrerPolicy="strict-origin-when-cross-origin"></iframe></div></figure></div></article><section class="bg-main-background py-0 overflow-hidden px-6 md:px-6 xl:px-[104px] 3xl:px-[284px] pb-[107px] md:pb-[143px] xl:pb-[178px] 3xl:pb-[200px]"><div class="mx-auto max-w-[1280px] px-0 3xl:max-w-[776px]"><div class="flex flex-col gap-6 md:gap-6 3xl:gap-[24px] items-center justify-center px-0 md:px-12 3xl:pl-[48px] 3xl:pr-[40px] 3xl:pt-0 rounded-[32px]"><div class="bg-main-background flex flex-col gap-[3.367px] items-start overflow-hidden relative"><div class="relative h-[267.418px] w-[352px] md:h-[277px] md:w-[352px] 3xl:h-[378px] 3xl:w-[542px]"><img alt="" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" sizes="(max-width: 1919px) 352px, 542px" srcSet="/_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=32&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 32w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=48&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 48w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=64&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 64w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=96&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 96w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=128&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 128w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=256&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 256w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=384&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 384w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=640&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 640w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=750&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 750w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=828&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 828w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=1080&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 1080w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=1200&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 1200w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=1920&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 1920w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=2048&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 2048w, /_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=3840&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E 3840w" src="/_next/image?url=%2Fimages%2Fhome-cta%2Fcta-decoration.webp&amp;w=3840&amp;q=75&amp;dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></div><div class="flex flex-col gap-7 md:gap-[28px] 3xl:gap-[32px] items-center md:items-center 3xl:items-center justify-center w-full"><div class="flex flex-col gap-3 md:gap-3 3xl:gap-[12px] items-start md:items-center justify-center text-center w-full"><h3 class="animate-on-scroll font-general-sans text-[28px] md:text-[28px] 3xl:text-[48px] font-medium leading-[1.1] text-white-custom mx-auto">Your agents are ready. <span class="block">Give them the context to act.</span></h3><div class="flex flex-col font-inter text-sm md:text-base 3xl:text-lg font-normal text-grey leading-[normal] md:leading-[1.2] xl:leading-[1.45] w-full max-w-full md:max-w-[388px] 3xl:max-w-[438px]"><p class="animate-on-scroll mb-0">Causely is the missing layer between your observability data and autonomous operations.</p></div></div><div class="flex gap-3 justify-center w-full"><a class="whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group items-center relative flex-1 flex justify-end" href="/try"><div class="rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden bg-[linear-gradient(to_right,#07bc85_0%,#8dfcdb_90%,#8dfcdb_100%)] relative z-10 lg:mr-[-5px]"><span class="font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-black">Talk to us</span></div><div class="relative overflow-hidden -ml-[5px] z-10 bg-causely-green-300 rounded-full p-4 w-[52px] h-[52px] items-center justify-center transition-all duration-200 ease-out hidden md:flex"><img alt="Arrow" loading="lazy" width="20" height="20" decoding="async" data-nimg="1" class="w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out lg:group-hover:translate-x-[200%]" style="color:transparent" src="/images/icons/dotted-arrow.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/><img alt="Arrow" loading="lazy" width="20" height="20" decoding="async" data-nimg="1" class="hidden lg:block absolute w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out opacity-0 -translate-x-[200%] lg:group-hover:opacity-100 lg:group-hover:translate-x-0" style="color:transparent" src="/images/icons/dotted-arrow.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></a><a href="https://auth.causely.app/oauth/account/sign-up" target="_self" class="whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group items-center relative flex-1 flex justify-start"><div class="rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden border border-white-custom group-hover:border-causely-green"><span class="font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-white-custom group-hover:text-causely-green">Try now</span></div></a></div></div></div></div></section></div><!--$--><!--/$--><footer class="bg-footer-bg px-8 py-10 xl:px-[120px] xl:py-[65px] 3xl:px-[180px] 3xl:py-[100px]"><div class="mx-auto xl:max-w-[1078px] 3xl:max-w-[1560px] flex flex-col gap-[33px] 3xl:items-center 3xl:justify-center"><div class="flex flex-col gap-10 md:gap-[33px] w-full 3xl:w-full"><div class="flex flex-col md:flex-row gap-10 md:gap-0 md:items-start 3xl:items-start md:justify-between"><div class="flex flex-col gap-10 md:gap-8 3xl:gap-8 w-full md:w-[358px] md:pr-[45px] xl:pr-0"><div class="h-[40px] w-[126.547px] md:h-[52px] md:w-[164px] xl:h-[42px] xl:w-[132px] relative"><img alt="Causely" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" src="/images/causely-logo-white.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div><div class="w-full xl:mt-2"><div class="flex flex-col gap-3 w-full xl:w-[542px]"><h3 class="font-dm-mono text-xs text-causely-glow tracking-[1px] uppercase leading-[15px]">SUBSCRIBE TO OUR MAILING LIST</h3><form class="flex gap-3 items-start" noValidate="" id="footer-newsletter-form" data-hs-form="false"><div class="flex-1 w-full md:w-auto min-w-0"><div class="flex flex-col gap-[12px] w-full"><div class="flex items-center pl-0 pr-[5px]"><input type="email" class="bg-main-background border rounded-[12px] text-[16px] font-general-sans font-medium leading-[1] focus-visible:outline-none disabled:cursor-not-allowed disabled:opacity-50 -mr-[5px] w-full px-4 py-3 border-grey-300 focus:border-causely-glow text-grey-400 focus:text-white-custom placeholder:text-input-placeholder focus-visible:ring-2 focus-visible:ring-causely-glow focus-visible:ring-offset-2 focus-visible:ring-offset-footer-bg" placeholder="Enter your email" aria-label="Email address" value=""/></div></div></div><button class="justify-center whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group flex items-center relative xl:w-[105px]" type="submit"><div class="rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden bg-[linear-gradient(to_right,#07bc85_0%,#8dfcdb_90%,#8dfcdb_100%)] relative z-10 lg:mr-[-5px] hover:!bg-[linear-gradient(to_right,#00000000,#00000000)] border-0 group-hover:border group-hover:border-causely-green"><span class="font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-black group-hover:text-causely-green">Send</span></div></button></form></div></div><div class="hidden font-[400] md:flex flex-col gap-[3px] md:gap-[5px] 3xl:gap-[10px]"><div class="flex flex-nowrap gap-[18.5px] items-center"><p class="font-dm-mono text-sm 3xl:text-lg text-white tracking-[1.69px] uppercase leading-[25.5px] whitespace-nowrap">Made with</p><div class="h-[33px] w-[36px] relative flex-shrink-0"><img alt="" aria-hidden="true" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" src="/images/icons/dotted-heart.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div><p class="font-dm-mono text-sm 3xl:text-lg text-white tracking-[1.69px] uppercase leading-[25.5px] whitespace-nowrap">in new york</p></div><p class="font-dm-mono text-sm 3xl:text-lg text-white tracking-[1.69px] uppercase leading-[25.5px] whitespace-pre">and around the world.</p></div></div><div class="flex flex-col md:flex-row gap-10 md:gap-16"><div><p class="font-dm-mono text-xs uppercase tracking-[1.5px] text-white/40 mb-4">Product</p><nav class="flex flex-col gap-3"><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/product">Overview</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/product/benchmark">Benchmark</a></nav></div><div><p class="font-dm-mono text-xs uppercase tracking-[1.5px] text-white/40 mb-4">Use Cases</p><nav class="flex flex-col gap-3"><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/product/ai-sre">Build an AI SRE</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/product/observability-costs">Reduce Observability Costs</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/product/agentic-apps">Observe AI Workloads</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/product/business-outcomes">Connect Business Outcomes</a></nav></div><div><p class="font-dm-mono text-xs uppercase tracking-[1.5px] text-white/40 mb-4">Company</p><nav class="flex flex-col gap-3"><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/about-us">About us</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/blog">Blog</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/pricing">Pricing</a><a class="font-sans whitespace-nowrap text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/security">Security</a></nav></div></div></div><div class="flex flex-col gap-[3px] md:hidden"><div class="flex flex-wrap gap-[18.5px] items-end"><p class="font-dm-mono text-sm text-white tracking-[1.69px] uppercase leading-[25.5px] whitespace-pre">Made with</p><div class="h-[33px] w-[36px] relative"><img alt="" aria-hidden="true" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" src="/images/icons/dotted-heart.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div><p class="font-dm-mono text-sm text-white tracking-[1.69px] uppercase leading-[25.5px] whitespace-pre">in new york</p></div><p class="font-dm-mono text-sm text-white tracking-[1.69px] uppercase leading-[25.5px] whitespace-pre">and around the world.</p></div><div class="w-full h-px bg-causely-green"></div><div class="flex flex-col md:flex-row items-start md:items-center justify-between w-full gap-6 md:gap-0"><div class="flex gap-3 w-full md:w-auto justify-start"><a target="_blank" rel="noopener noreferrer" class="border border-grey rounded-[30px] w-[50px] h-[50px] md:w-[38px] md:h-[38px] flex items-center justify-center lg:hover:bg-gradient-to-r lg:hover:from-causely-green lg:hover:to-causely-green-300 lg:hover:border-footer-bg transition-all group" aria-label="LinkedIn" href="https://www.linkedin.com/company/causely-ai/"><div class="w-[26px] h-[26px] md:w-5 md:h-5 relative [&amp;&gt;img]:transition-all [&amp;&gt;img]:brightness-100 lg:group-hover:[&amp;&gt;img]:brightness-0"><img alt="" aria-hidden="true" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" src="/images/icons/linkedin.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></a><a target="_blank" rel="noopener noreferrer" class="border border-grey rounded-[30px] w-[50px] h-[50px] md:w-[38px] md:h-[38px] flex items-center justify-center lg:hover:bg-gradient-to-r lg:hover:from-causely-green lg:hover:to-causely-green-300 lg:hover:border-footer-bg transition-all group" aria-label="X (Twitter)" href="https://twitter.com/Causelyai"><div class="w-[26px] h-[26px] md:w-5 md:h-5 relative [&amp;&gt;img]:transition-all [&amp;&gt;img]:brightness-100 lg:group-hover:[&amp;&gt;img]:brightness-0"><img alt="" aria-hidden="true" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" src="/images/icons/x.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></a><a target="_blank" rel="noopener noreferrer" class="border border-grey rounded-[30px] w-[50px] h-[50px] md:w-[38px] md:h-[38px] flex items-center justify-center lg:hover:bg-gradient-to-r lg:hover:from-causely-green lg:hover:to-causely-green-300 lg:hover:border-footer-bg transition-all group" aria-label="YouTube" href="https://www.youtube.com/@Causely-ai"><div class="w-[26px] h-[26px] md:w-5 md:h-5 relative [&amp;&gt;img]:transition-all [&amp;&gt;img]:brightness-100 lg:group-hover:[&amp;&gt;img]:brightness-0"><img alt="" aria-hidden="true" loading="lazy" decoding="async" data-nimg="fill" class="object-contain" style="position:absolute;height:100%;width:100%;left:0;top:0;right:0;bottom:0;color:transparent" src="/images/icons/youtube.svg?dpl=dpl_MN81ko9c8G2XkeHz1xLBkP1rX43E"/></div></a></div><nav class="flex flex-wrap gap-x-6 gap-y-3"><a class="font-sans text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/privacy-policy">Privacy policy</a><a class="font-sans text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/terms-of-service">Terms of service</a><a class="font-sans text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors" href="/security">Security contact</a><button class="font-sans text-base font-normal text-white leading-[1.45] hover:text-causely-green transition-colors text-left" aria-label="Open cookie settings">Cookie settings</button></nav><p class="font-dm-mono text-xs text-white tracking-[1px] uppercase leading-[15px] text-left">© 2026 Causely, Inc. ALL rights reserved.</p></div></div></div></footer></main></div><!--$--><!--/$--></div></div><script src="/_next/static/immutable/chunks/17tuxysuvqwd2.js" id="_R_" async=""></script><script>(self.__next_f=self.__next_f||[]).push([0])</script><script>self.__next_f.push([1,"1:\"$Sreact.fragment\"\n2:I[69024,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"default\"]\n3:I[1613,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"Providers\"]\n4:I[80492,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"ThemeProvider\"]\n5:I[39756,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"default\"]\n6:I[8821,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/0qn98tgsfm7pc.js\"],\"default\"]\n7:I[37457,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"default\"]\n8:I[5500,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\",\"/_next/static/immutable/chunks/3cxalgnb-xm18.js\",\"/_next/static/immutable/chunks/3ithhqp6kca4w.js\"],\"Image\"]\n16:I[68027,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"default\",1]\n:HL[\"/_next/static/immutable/chunks/3vdpttbswk5bm.css\",\"style\"]\n:HL[\"/_next/static/immutable/chunks/3trq96g6e7_2e.css\",\"style\"]\n:HL[\"/_next/static/immutable/media/GeneralSans_Bold-s.p.2e10_-xm6yxi6.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/immutable/media/GeneralSans_Extralight-s.p.0riuhb1noeeh7.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/immutable/media/GeneralSans_Light-s.p.0w6i39gm3pfpd.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/immutable/media/GeneralSans_Medium-s.p.0k_79f4guym1z.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/immutable/media/GeneralSans_Regular-s.p.2bw9n2r1d6id1.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n:HL[\"/_next/static/immutable/media/GeneralSans_Semibold-s.p.43ayu7ok-ea8v.woff2\",\"font\",{\"crossOrigin\":\"\",\"type\":\"font/woff2\"}]\n14:X\n0:{\"P\":null,\"c\":[\"\",\"blog\",\"kubernetes-oom-killer-tips\"],\"q\":\"\",\"i\":false,\"f\":[[[\"\",{\"children\":[\"(main)\",{\"children\":[\"blog\",{\"children\":[[\"slug\",\"kubernetes-oom-killer-tips\",\"d\",[]],{\"children\":[\"__PAGE__\",{},\"$undefined\",\"$undefined\",4096]},\"$undefined\",\"$undefined\",4096]},\"$undefined\",\"$undefined\",4096]},\"$undefined\",\"$undefined\",4096]},\"$undefined\",\"$undefined\",4112],[[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/immutable/chunks/3vdpttbswk5bm.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/immutable/chunks/3trq96g6e7_2e.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/immutable/chunks/011me_93942kq.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-2\",{\"src\":\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-3\",{\"src\":\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-4\",{\"src\":\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"html\",null,{\"lang\":\"en\",\"suppressHydrationWarning\":true,\"className\":\"dark\",\"children\":[[\"$\",\"head\",null,{\"children\":[\"$\",\"$L2\",null,{}]}],[\"$\",\"body\",\"root-layout\",{\"className\":\"inter_4259f421-module__8cy6qW__variable dm_mono_d7d5bd4-module__m3ieCa__variable generalsans_a3c20b4-module__cx286q__variable flex min-h-screen flex-col\",\"suppressHydrationWarning\":true,\"children\":[\"$\",\"$L3\",null,{\"children\":[\"$\",\"$L4\",null,{\"attribute\":\"class\",\"defaultTheme\":\"dark\",\"enableSystem\":false,\"disableTransitionOnChange\":true,\"children\":[[\"$\",\"div\",null,{\"className\":\"relative flex min-h-screen flex-col bg-main-background\",\"children\":[\"$\",\"main\",null,{\"className\":\"flex-1 bg-main-background\",\"children\":[\"$\",\"$L5\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$6\",\"errorStyles\":[],\"errorScripts\":[[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/immutable/chunks/0qn98tgsfm7pc.js\",\"async\":true}]],\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[\"$\",\"section\",null,{\"className\":\"relative min-h-screen bg-main-background flex justify-center items-center px-4 md:px-6 overflow-hidden\",\"children\":[[\"$\",\"div\",null,{\"className\":\"absolute inset-0 opacity-50 pointer-events-none\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/try-page/grid.svg\",\"alt\":\"\",\"fill\":true,\"className\":\"object-cover\",\"aria-hidden\":\"true\",\"priority\":true}]}],[\"$\",\"div\",null,{\"className\":\"absolute inset-0 pointer-events-none\",\"style\":{\"background\":\"radial-gradient(102.08% 90% at 50% 50%, rgba(11, 16, 29, 0.00) 0%, #020817 100%)\"},\"aria-hidden\":\"true\"}],[\"$\",\"div\",null,{\"className\":\"absolute z-10 top-0 left-0 right-0 h-[250px] md:h-[380px] 3xl:h-[400px] pointer-events-none\",\"style\":{\"background\":\"linear-gradient(180deg, #020817 0%, rgba(2, 8, 23, 0.8) 50%, rgba(2, 8, 23, 0) 100%)\"},\"aria-hidden\":\"true\"}],[\"$\",\"div\",null,{\"className\":\"absolute z-10 bottom-0 left-0 right-0 h-[270px] md:h-[380px] 3xl:h-[400px] pointer-events-none\",\"style\":{\"background\":\"linear-gradient(0deg, #020817 0%, rgba(2, 8, 23, 0.8) 50%, rgba(2, 8, 23, 0) 100%)\"},\"aria-hidden\":\"true\"}],[\"$\",\"div\",null,{\"className\":\"absolute top-0 left-1/2 -translate-x-1/2 pointer-events-none\",\"children\":[\"$\",\"div\",null,{\"className\":\"relative w-[380px] md:w-[636px] 3xl:w-[636px] h-[158px] md:h-[265px] 3xl:h-[265px]\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/error-page/404.svg\",\"alt\":\"\",\"fill\":true,\"className\":\"object-contain\",\"aria-hidden\":\"true\",\"priority\":true}]}]}],[\"$\",\"div\",null,{\"className\":\"absolute bottom-0 left-1/2 -translate-x-1/2 pointer-events-none\",\"children\":[\"$\",\"div\",null,{\"className\":\"relative w-[380px] md:w-[636px] 3xl:w-[636px] h-[158px] md:h-[265px] 3xl:h-[265px]\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/error-page/404.svg\",\"alt\":\"\",\"fill\":true,\"className\":\"object-contain\",\"aria-hidden\":\"true\",\"priority\":true}]}]}],[\"$\",\"div\",null,{\"className\":\"relative z-10 flex flex-col items-center justify-center gap-[18px] md:gap-[28px] text-center max-w-[360px] md:max-w-[800px] xl:max-w-full w-full px-6 md:px-0\",\"children\":[[\"$\",\"h1\",null,{\"className\":\"font-general-sans text-[28px] md:text-[48px] 3xl:text-[64px] font-medium text-white-custom leading-[1.1] md:leading-[1.2] 3xl:leading-[1.1]\",\"children\":[\"$L9\",\" \",\"$La\"]}],\"$Lb\",\"$Lc\"]}]]}],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]}]}],\"$Ld\",\"$Le\",\"$Lf\"]}]}]}]]}]]}],{\"children\":[\"$L10\",{\"children\":[\"$L11\",{\"children\":[\"$L12\",{\"children\":[\"$L13\",{},null,false,null]},null,false,\"$14\"]},null,false,\"$14\"]},null,false,null]},null,false,null],\"$L15\",false]],\"m\":\"$undefined\",\"G\":[\"$16\",[\"$L17\",\"$L18\"]],\"S\":false,\"h\":null,\"r\":\"$undefined\",\"s\":\"$undefined\",\"a\":\"$undefined\",\"l\":\"$undefined\",\"p\":\"$undefined\",\"d\":\"$undefined\"}\n19:I[22016,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\",\"/_next/static/immutable/chunks/3cxalgnb-xm18.js\",\"/_next/static/immutable/chunks/3ithhqp6kca4w.js\"],\"\"]\n1a:I[92016,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"CookieConsent\"]\n1b:I[57215,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"SpeedInsights\"]\n1c:I[43880,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"Analytics\"]\n1d:I[9454,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\"],\"PromoBanner\"]\n1e:I[76558,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\"],\"SiteHeader\"]\n22:I[97367,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"OutletBoundary\"]\n23:\"$Sreact.suspense\"\n25:I[97367,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"ViewportBoundary\"]\n27:I[97367,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"MetadataBoundary\"]\n9:[\"$\",\"span\",null,{\"className\":\"block xl:inline\",\"children\":\"Sorry!\"}]\na:[\"$\",\"span\",null,{\"className\":\"block xl:inline\",\"children\":\"We couldn't find that page.\"}]\nb:[\"$\",\"div\",null,{\"className\":\"flex flex-col gap-0 font-inter text-base md:text-lg 3xl:text-[18px] font-normal text-grey leading-[1.45] tracking-[-0.35px] w-full md:max-w-[586px]\",\"children\":[[\"$\",\"p\",null,{\"className\":\"mb-0\",\"children\":\"We have our own errors sometimes, too.\"}],[\"$\",\"p\",null,{\"children\":\"The page you're looking for doesn't exist or may have been moved.\"}]]}]\nc:[\"$\",\"div\",null,{\"className\":\"flex items-center justify-center mt-[10px] md:mt-[12px]\",\"children\":[\"$\",\"$L19\",null,{\"href\":\"/\",\"className\":\"justify-center whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group flex items-center relative\",\"children\":[[\"$\",\"div\",null,{\"className\":\"rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden bg-[linear-gradient(to_right,#07bc85_0%,#8dfcdb_90%,#8dfcdb_100%)] relative z-10 lg:mr-[-5px]\",\"children\":[\"$\",\"span\",null,{\"className\":\"font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-black\",\"children\":\"Return home\"}]}],[\"$\",\"div\",null,{\"className\":\"relative flex overflow-hidden -ml-[5px] z-10 bg-causely-green-300 rounded-full p-4 w-[52px] h-[52px] items-center justify-center transition-all duration-200 ease-out\",\"children\":[[\"$\",\"$L8\",null,{\"src\":\"/images/icons/dotted-arrow.svg\",\"alt\":\"Arrow\",\"width\":20,\"height\":20,\"className\":\"w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out lg:group-hover:translate-x-[200%]\"}],[\"$\",\"$L8\",null,{\"src\":\"/images/icons/dotted-arrow.svg\",\"alt\":\"Arrow\",\"width\":20,\"height\":20,\"className\":\"hidden lg:block absolute w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out opacity-0 -translate-x-[200%] lg:group-hover:opacity-100 lg:group-hover:translate-x-0\"}]]}]]}]}]\nd:[\"$\",\"$L1a\",null,{}]\ne:[\"$\",\"$L1b\",null,{}]\nf:[\"$\",\"$L1c\",null,{}]\n10:[\"$\",\"$1\",\"c\",{\"children\":[[[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[[\"$\",\"$L1d\",null,{}],[\"$\",\"$L1e\",null,{}],[\"$\",\"$L5\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":[[\"$\",\"section\",null,{\"className\":\"relative min-h-screen bg-main-background flex justify-center items-center px-4 md:px-6 overflow-hidden\",\"children\":[[\"$\",\"div\",null,{\"className\":\"absolute inset-0 opacity-50 pointer-events-none\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/try-page/grid.svg\",\"alt\":\"\",\"fill\":true,\"className\":\"object-cover\",\"aria-hidden\":\"true\",\"priority\":true}]}],[\"$\",\"div\",null,{\"className\":\"absolute inset-0 pointer-events-none\",\"style\":{\"background\":\"radial-gradient(102.08% 90% at 50% 50%, rgba(11, 16, 29, 0.00) 0%, #020817 100%)\"},\"aria-hidden\":\"true\"}],[\"$\",\"div\",null,{\"className\":\"absolute z-10 top-0 left-0 right-0 h-[250px] md:h-[380px] 3xl:h-[400px] pointer-events-none\",\"style\":{\"background\":\"linear-gradient(180deg, #020817 0%, rgba(2, 8, 23, 0.8) 50%, rgba(2, 8, 23, 0) 100%)\"},\"aria-hidden\":\"true\"}],[\"$\",\"div\",null,{\"className\":\"absolute z-10 bottom-0 left-0 right-0 h-[270px] md:h-[380px] 3xl:h-[400px] pointer-events-none\",\"style\":{\"background\":\"linear-gradient(0deg, #020817 0%, rgba(2, 8, 23, 0.8) 50%, rgba(2, 8, 23, 0) 100%)\"},\"aria-hidden\":\"true\"}],[\"$\",\"div\",null,{\"className\":\"absolute top-0 left-1/2 -translate-x-1/2 pointer-events-none\",\"children\":[\"$\",\"div\",null,{\"className\":\"relative w-[380px] md:w-[636px] 3xl:w-[636px] h-[158px] md:h-[265px] 3xl:h-[265px]\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/error-page/404.svg\",\"alt\":\"\",\"fill\":true,\"className\":\"object-contain\",\"aria-hidden\":\"true\",\"priority\":true}]}]}],[\"$\",\"div\",null,{\"className\":\"absolute bottom-0 left-1/2 -translate-x-1/2 pointer-events-none\",\"children\":[\"$\",\"div\",null,{\"className\":\"relative w-[380px] md:w-[636px] 3xl:w-[636px] h-[158px] md:h-[265px] 3xl:h-[265px]\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/error-page/404.svg\",\"alt\":\"\",\"fill\":true,\"className\":\"object-contain\",\"aria-hidden\":\"true\",\"priority\":true}]}]}],[\"$\",\"div\",null,{\"className\":\"relative z-10 flex flex-col items-center justify-center gap-[18px] md:gap-[28px] text-center max-w-[360px] md:max-w-[800px] xl:max-w-full w-full px-6 md:px-0\",\"children\":[[\"$\",\"h1\",null,{\"className\":\"font-general-sans text-[28px] md:text-[48px] 3xl:text-[64px] font-medium text-white-custom leading-[1.1] md:leading-[1.2] 3xl:leading-[1.1]\",\"children\":[[\"$\",\"span\",null,{\"className\":\"block xl:inline\",\"children\":\"Sorry!\"}],\" \",[\"$\",\"span\",null,{\"className\":\"block xl:inline\",\"children\":\"We couldn't find that page.\"}]]}],[\"$\",\"div\",null,{\"className\":\"flex flex-col gap-0 font-inter text-base md:text-lg 3xl:text-[18px] font-normal text-grey leading-[1.45] tracking-[-0.35px] w-full md:max-w-[586px]\",\"children\":[[\"$\",\"p\",null,{\"className\":\"mb-0\",\"children\":\"We have our own errors sometimes, too.\"}],[\"$\",\"p\",null,{\"children\":\"The page you're looking for doesn't exist or may have been moved.\"}]]}],[\"$\",\"div\",null,{\"className\":\"flex items-center justify-center mt-[10px] md:mt-[12px]\",\"children\":[\"$\",\"$L19\",null,{\"href\":\"/\",\"className\":\"justify-center whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group flex items-center relative\",\"children\":[[\"$\",\"div\",null,{\"className\":\"rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden bg-[linear-gradient(to_right,#07bc85_0%,#8dfcdb_90%,#8dfcdb_100%)] relative z-10 lg:mr-[-5px]\",\"children\":[\"$\",\"span\",null,{\"className\":\"font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-black\",\"children\":\"Return home\"}]}],\"$L1f\"]}]}]]}]]}],[]],\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}],\"$L20\"]]}]\n11:[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L5\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}]\n12:[\"$\",\"$1\",\"c\",{\"children\":[null,[\"$\",\"$L5\",null,{\"parallelRouterKey\":\"children\",\"error\":\"$undefined\",\"errorStyles\":\"$undefined\",\"errorScripts\":\"$undefined\",\"template\":[\"$\",\"$L7\",null,{}],\"templateStyles\":\"$undefined\",\"templateScripts\":\"$undefined\",\"notFound\":\"$undefined\",\"forbidden\":\"$undefined\",\"unauthorized\":\"$undefined\"}]]}]\n13:[\"$\",\"$1\",\"c\",{\"children\":[\"$L21\",[[\"$\",\"script\",\"script-0\",{\"src\":\"/_next/static/immutable/chunks/3cxalgnb-xm18.js\",\"async\":true,\"nonce\":\"$undefined\"}],[\"$\",\"script\",\"script-1\",{\"src\":\"/_next/static/immutable/chunks/3ithhqp6kca4w.js\",\"async\":true,\"nonce\":\"$undefined\"}]],[\"$\",\"$L22\",null,{\"children\":[\"$\",\"$23\",null,{\"name\":\"Next.MetadataOutlet\",\"children\":\"$@24\"}]}]]}]\n15:[\"$\",\"$1\",\"h\",{\"children\":[null,[\"$\",\"$L25\",null,{\"children\":\"$L26\"}],[\"$\",\"div\",null,{\"hidden\":true,\"children\":[\"$\",\"$L27\",null,{\"children\":[\"$\",\"$23\",null,{\"name\":\"Next.Metadata\",\"children\":\"$L28\"}]}]}],[\"$\",\"meta\",null,{\"name\":\"next-size-adjust\",\"content\":\"\"}]]}]\n17:[\"$\",\"link\",\"0\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/immutable/chunks/3vdpttbswk5bm.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]\n18:[\"$\",\"link\",\"1\",{\"rel\":\"stylesheet\",\"href\":\"/_next/static/immutable/chunks/3trq96g6e7_2e.css\",\"precedence\":\"next\",\"crossOrigin\":\"$undefined\",\"nonce\":\"$undefined\"}]\n29:I[56399,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\"],\"SiteFooter\"]\n14:C\n1f:[\"$\",\"div\",null,{\"className\":\"relative flex overflow-hidden -ml-[5px] z-10 bg-causely-green-300 rounded-full p-4 w-[52px] h-[52px] items-center justify-center transition-all duration-200 ease-out\",\"children\":[[\"$\",\"$L8\",null,{\"src\":\"/images/icons/dotted-arrow.svg\",\"alt\":\"Arrow\",\"width\":20,\"height\":20,\"className\":\"w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out lg:group-hover:translate-x-[200%]\"}],[\"$\",\"$L8\",null,{\"src\":\"/images/icons/dotted-arrow.svg\",\"alt\":\"Arrow\",\"width\":20,\"height\":20,\"className\":\"hidden lg:block absolute w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out opacity-0 -translate-x-[200%] lg:group-hover:opacity-100 lg:group-hover:translate-x-0\"}]]}]\n20:[\"$\",\"$L29\",null,{}]\n26:[[\"$\",\"meta\",\"0\",{\"charSet\":\"utf-8\"}],[\"$\",\"meta\",\"1\",{\"name\":\"viewport\",\"content\":\"width=device-width, initial-scale=1\"}],[\"$\",\"meta\",\"2\",{\"name\":\"theme-color\",\"content\":\"#020817\"}]]\n2a:I[97531,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\",\"/_next/static/immutable/chunks/3cxalgnb-xm18.js\",\"/_next/static/immutable/chunks/3ithhqp6kca4w.js\"],\"BlogPostRender\"]\n2d:I[27201,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\"],\"IconMark\"]\n2b:T3172,\u003cp\u003eRunning containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernetes kernel’s OOM killer disrupts application stability and can affect application availability and the health of your overall environment.\u003c/p\u003e\u003cp\u003eIn this post, we’ll explore the reasons that OOM kills can occur and provide tactics to combat and prevent them.\u003c/p\u003e\u003cp\u003eBefore diving in, it’s worth noting that OOM kills represent one symptom that can have a variety of root causes. It’s important for organizations to implement a system that solves the root cause analysis problem with speed and accuracy, allowing reliability engineering teams to respond rapidly, and to potentially prevent these occurrences in the first place.\u003c/p\u003e\u003ch2 id=\"deep-dive-into-an-oom-kill\"\u003eDeep dive into an OOM kill\u003c/h2\u003e\u003cp\u003eAn Out-Of-Memory (OOM) kill in \u003ca href=\"https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io\"\u003eKubernetes\u003c/a\u003e occurs when a container exceeds its memory limit, causing the Kubernetes kernel’s OOM killer to terminate the container. This impacts application stability and requires immediate attention.\u003c/p\u003e\u003cp\u003eSeveral factors can trigger OOM kills in your Kubernetes environment, including:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003cstrong\u003eMemory limits exceeded:\u003c/strong\u003e This is the most common culprit. If a container consistently pushes past its designated memory ceiling, the OOM killer steps in to prevent a system-wide meltdown.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eMemory leaks:\u003c/strong\u003e Applications can develop memory leaks over time, where they allocate memory but fail to release it properly. This hidden, unexpected growth eventually leads to OOM kills.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eResource overcommitment:\u003c/strong\u003e Co-locating too many resource-hungry pods onto a single node can deplete available memory. When the combined memory usage exceeds capacity, the OOM killer springs into action.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eBursting workloads:\u003c/strong\u003e Applications with spiky workloads can experience sudden memory surges that breach their limits, triggering OOM kills.\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eAs an example, a web server that experiences a memory leak code bug may gradually consume more and more memory until the OOM killer intervenes to prevent a crash.\u003c/p\u003e\u003cp\u003eAnother case could be when a Kubernetes cluster over-commits resources by scheduling too many pods on a single node. The OOM killer may need to step in to free up memory and ensure system stability.\u003c/p\u003e\u003ch2 id=\"the-devastating-effects-of-oom-kills-why-they-matter\"\u003eThe devastating effects of OOM kills: Why they matter\u003c/h2\u003e\u003cp\u003eOOM kills aren’t normally occurring events. They can trigger a cascade of negative consequences for your applications and the overall health of the cluster, such as:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003cstrong\u003eApplication downtime:\u003c/strong\u003e When a container is OOM-killed, it abruptly terminates, causing immediate application downtime. Users may experience service disruptions and outages.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eData loss:\u003c/strong\u003e Applications that rely on in-memory data or stateful sessions risk losing critical information during an OOM kill.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003ePerformance degradation:\u003c/strong\u003e Frequent OOM kills force containers to restart repeatedly. This constant churn degrades overall application performance and user experience.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eService disruption:\u003c/strong\u003e Applications often interact with each other. An OOM kill in one container can disrupt inter-service communication, causing cascading failures and broader service outages.\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eIf a container running a critical database service experiences an OOM kill, it could result in data loss and corruption. This leads to service disruptions for other containers that rely on the database for information, causing cascading failures across the entire application ecosystem.\u003c/p\u003e\u003ch2 id=\"combating-oom-kills\"\u003eCombating OOM kills\u003c/h2\u003e\u003cp\u003eThere are a few different tactics to combat OOM kills in attempt to operate a memory-efficient Kubernetes environment.\u003c/p\u003e\u003ch3 id=\"set-appropriate-resource-requests-and-limits\"\u003eSet appropriate resource requests and limits\u003c/h3\u003e\u003cp\u003eFor example, you can set a memory request of 200Mi and a memory limit of 300Mi for a particular container in your Kubernetes deployment. Requests ensure the container gets at least 200Mi of memory, while limits cap it at 300Mi to prevent excessive consumption.\u003c/p\u003e\u003cpre\u003e\u003ccode class=\"language-json\"\u003eresources:\n requests:\n memory: \"200Mi\"\n limits:\n memory: \"300Mi\"\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eWhile this may mitigate potential memory use issues, it is a very manual process and does not deal at all with the dynamic nature of what we can achieve with Kubernetes. It also doesn’t solve the source issue, which may be a code-level problem triggering memory leaks or failed GC processes.\u003c/p\u003e\u003ch3 id=\"transition-to-autoscaling\"\u003eTransition to autoscaling\u003c/h3\u003e\u003cp\u003eLeveraging \u003ca href=\"https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io\"\u003eautoscaling\u003c/a\u003e capabilities is a core dynamic option for resource allocation. There are two autoscaling methods:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\u003cstrong\u003eVertical Pod Autoscaling (VPA):\u003c/strong\u003e \u003ca href=\"https://kubernetes.io/docs/concepts/workloads/autoscaling/?ref=causely-blog.ghost.io\" rel=\"noopener\"\u003eVPA\u003c/a\u003e dynamically adjusts resource limits based on real-time memory usage patterns. This ensures containers have enough memory to function but avoids over-provisioning.\u003c/li\u003e\u003cli\u003e\u003cstrong\u003eHorizontal Pod Autoscaling (HPA):\u003c/strong\u003e \u003ca href=\"https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/?ref=causely-blog.ghost.io\" rel=\"noopener\"\u003eHPA\u003c/a\u003e scales the number of pods running your application up or down based on memory utilization. This distributes memory usage across multiple pods, preventing any single pod from exceeding its limit. The following HPA configuration shows an example of scaling based on memory usage:\u003c/li\u003e\u003c/ul\u003e\u003cpre\u003e\u003ccode class=\"language-json\"\u003eapiVersion: autoscaling/v2beta2\nkind: HorizontalPodAutoscaler\nmetadata:\n name: my-app-hpa\nspec:\n scaleTargetRef:\n apiVersion: apps/v1\n kind: Deployment\n name: my-app\n minReplicas: 2\n maxReplicas: 10\n metrics:\n - type: Resource\n resource:\n name: memory\n target:\n type: Utilization\n averageUtilization: 80\u003c/code\u003e\u003c/pre\u003e\u003ch3 id=\"monitor-memory-usage\"\u003eMonitor memory usage\u003c/h3\u003e\u003cp\u003eProactive monitoring is key. For instance, you can configure \u003ca href=\"https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io\"\u003ePrometheus\u003c/a\u003e to scrape memory metrics from your Kubernetes pods every 15 seconds and set up \u003ca href=\"https://grafana.com/?ref=causely-blog.ghost.io\" rel=\"noopener\"\u003eGrafana\u003c/a\u003e dashboards to visualize memory usage trends over time. Additionally, you can create alerts in Prometheus to trigger notifications when memory usage exceeds a certain threshold.\u003c/p\u003e\u003ch3 id=\"optimize-application-memory-usage\"\u003eOptimize application memory usage\u003c/h3\u003e\u003cp\u003eDon’t underestimate the power of code optimization. Address memory leaks within your applications and implement memory-efficient data structures to minimize memory consumption.\u003c/p\u003e\u003ch3 id=\"pool-disruption-budgets-pdb\"\u003ePool disruption budgets (PDB)\u003c/h3\u003e\u003cp\u003eWhen deploying updates, \u003ca href=\"https://www.causely.ai/resources/glossary-cloud-native-technologies/?ref=causely-blog.ghost.io\"\u003ePDBs\u003c/a\u003e ensure a minimum number of pods remain available, even during rollouts. This mitigates the risk of widespread OOM kills during deployments. Here is a PDB configuration example that helps ensure minimum pod availability.\u003c/p\u003e\u003cpre\u003e\u003ccode class=\"language-json\"\u003eapiVersion: policy/v1\nkind: PodDisruptionBudget\nmetadata:\n name: my-app-pdb\nspec:\n minAvailable: 80%\n selector:\n matchLabels:\n app: my-app\u003c/code\u003e\u003c/pre\u003e\u003ch3 id=\"manage-node-resources\"\u003eManage node resources\u003c/h3\u003e\u003cp\u003eYou can apply a node selector to ensure that a memory-intensive pod is only scheduled on nodes with a minimum of 8GB of memory. Additionally, you can use taints and tolerations to dedicate specific nodes with high memory capacity for memory-hungry applications, preventing OOM kills due to resource constraints.\u003c/p\u003e\u003cpre\u003e\u003ccode class=\"language-json\"\u003enodeSelector:\n disktype: ssd\ntolerations:\n - key: \"key\"\n operator: \"Equal\"\n value: \"value\"\n effect: \"NoSchedule\"\u003c/code\u003e\u003c/pre\u003e\u003ch3 id=\"use-qos-classes\"\u003eUse QoS classes\u003c/h3\u003e\u003cp\u003eKubernetes offers Quality of Service (\u003ca href=\"https://kubernetes.io/docs/concepts/workloads/pods/pod-qos/?ref=causely-blog.ghost.io\" rel=\"noopener\"\u003eQoS\u003c/a\u003e) classes that prioritize resource allocation for critical applications. Assign the highest QoS class to applications that can least tolerate OOM kills. Here is a sample resource configuration with QoS parameters:\u003c/p\u003e\u003cpre\u003e\u003ccode class=\"language-json\"\u003eresources:\n requests:\n memory: \"1Gi\"\n cpu: \"500m\"\n limits:\n memory: \"1Gi\"\n cpu: \"500m\"\u003c/code\u003e\u003c/pre\u003e\u003cp\u003eThese are a few potential strategies to help prevent OOM kills. The challenge comes with the frequency with which they can occur, and the risk to your applications when they happen.\u003c/p\u003e\u003cp\u003eAs you can imagine, it’s not possible to manually manage resource utilization, and guarantee the stability and performance of your containerized applications within your Kubernetes environment.\u003c/p\u003e\u003ch2 id=\"manual-thresholds-rigidity-and-risk\"\u003eManual thresholds = Rigidity and risk\u003c/h2\u003e\u003cp\u003eThese techniques can help reduce the risk of OOM kills. The issue is not entirely solved though. By setting manual thresholds and limits, you’re removing many of the dynamic advantages of Kubernetes.\u003c/p\u003e\u003cp\u003eA more ideal way to solve the OOM kill problem is to use adaptive, dynamic resource allocation. Even if you get resource allocation right on initial deployment, there are many factors that change that affect how your application consumes resources. There is also a risk because application and resource issues don’t just affect one pod, or one container. Resource issues can reach every part of the cluster and degrade the other running applications and services.\u003c/p\u003e\u003ch2 id=\"which-strategy-works-best-to-prevent-oom-kills\"\u003eWhich strategy works best to prevent OOM kills?\u003c/h2\u003e\u003cp\u003eVertical Pod Autoscaling (VPA) and Horizontal Pod Autoscaling (HPA) are common strategies used to manage resource limits in Kubernetes containers. VPA adjusts resource limits based on real-time memory usage patterns, while HPA scales pods based on memory utilization.\u003c/p\u003e\u003cp\u003eMonitoring with tools like Prometheus may help with the troubleshooting of memory usage trends. Optimizing application memory usage is no easy feat because it’s especially challenging to identify whether it is infrastructure or code causing the problem.\u003c/p\u003e\u003cp\u003ePod Disruption Budgets (PDB) may help ensure a minimum number of pods remain available during deployments, while node resources can be managed using node selectors and taints. Quality of Service (QoS) classes prioritize resource allocation for critical applications.\u003c/p\u003e\u003cp\u003eOne thing is certain: OOM kills are a common and costly challenge to manage using traditional monitoring tools and methods.\u003c/p\u003e\u003cp\u003eAt \u003ca href=\"https://www.causely.ai/?ref=causely-blog.ghost.io\"\u003eCausely\u003c/a\u003e, we’re focused on applying causal reasoning software to help organizations keep applications healthy and resilient. By automating root cause analysis, issues like OOM kills can be resolved in seconds, and unintended consequences of new releases or application changes can be avoided.\u003c/p\u003e\u003ch2 id=\"related-resources\"\u003eRelated resources\u003c/h2\u003e\u003cul\u003e\u003cli\u003e\u003ca href=\"https://www.causely.ai/blog/understanding-kubernetes-readiness-probe-to-ensure-your-applications-availability/?ref=causely-blog.ghost.io\"\u003eRead the blog\u003c/a\u003e: Understanding the Kubernetes Readiness Probe: A Tool for Application Health\u003c/li\u003e\u003cli\u003e\u003ca href=\"https://www.causely.ai/blog/bridging-the-gap-between-observability-and-automation-with-causal-reasoning/?ref=causely-blog.ghost.io\"\u003eRead the blog\u003c/a\u003e: Bridging the gap between observability and automation with causal reasoning\u003c/li\u003e\u003c/ul\u003e\u003cp\u003eWatch our webinar on Causal AI and why DevOps teams need it:\u003c/p\u003e\u003cfigure class=\"kg-card kg-embed-card\"\u003e\u003ciframe width=\"200\" height=\"150\" src=\"https://www.youtube.com/embed/pSl4pGCczOU?feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen=\"\" title=\"What is Causal AI and why do DevOps teams need it?\"\u003e\u003c/iframe\u003e\u003c/figure\u003e21:[\"$\",\"div\",null,{\"children\":[[\"$\",\"article\",null,{\"className\":\"container max-w-4xl py-12\",\"children\":[[\"$\",\"div\",null,{\"className\":\"mb-8\",\"children\":[[\"$\",\"h1\",null,{\"className\":\"text-4xl font-bold mb-4\",\"children\":\"Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management\"}],[\"$\",\"div\",null,{\"className\":\"flex items-center mb-8\",\"children\":[[\"$\",\"div\",null,{\"className\":\"flex -space-x-2 mr-3\",\"children\":[[\"$\",\"$L8\",\"677ed46c42c80600015a0611\",{\"src\":\"/images/newsroom/CauselyIcon.png\",\"alt\":\"Causely\",\"width\":40,\"height\":40,\"className\":\"rounded-full ring-2 ring-background\"}]]}],[\"$\",\"div\",null,{\"children\":[[\"$\",\"p\",null,{\"className\":\"font-medium\",\"children\":\"Causely\"}],[\"$\",\"p\",null,{\"className\":\"text-sm text-muted-foreground\",\"children\":\"August 28, 2024\"}]]}]]}]]}],[\"$\",\"div\",null,{\"className\":\"relative aspect-video mb-12\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"https://storage.ghost.io/c/f4/30/f4302d25-b539-4f59-b4cb-e3882f8f5026/content/images/wp-content/uploads/2024/08/preventing-oom-kills-1.png\",\"alt\":\"Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management\",\"fill\":true,\"className\":\"object-cover rounded-lg\"}]}],[\"$\",\"$L2a\",null,{\"content\":\"$2b\"}]]}],\"$L2c\"]}]\n24:null\n28:[[\"$\",\"title\",\"0\",{\"children\":\"Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management | Causely\"}],[\"$\",\"meta\",\"1\",{\"name\":\"description\",\"content\":\"Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernet\"}],[\"$\",\"link\",\"2\",{\"rel\":\"manifest\",\"href\":\"/manifest.json\",\"crossOrigin\":\"$undefined\"}],[\"$\",\"meta\",\"3\",{\"property\":\"og:title\",\"content\":\"Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management\"}],[\"$\",\"meta\",\"4\",{\"property\":\"og:description\",\"content\":\"Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernet\"}],[\"$\",\"meta\",\"5\",{\"property\":\"og:image\",\"content\":\"https://storage.ghost.io/c/f4/30/f4302d25-b539-4f59-b4cb-e3882f8f5026/content/images/wp-content/uploads/2024/08/preventing-oom-kills-1.png\"}],[\"$\",\"meta\",\"6\",{\"property\":\"og:image:width\",\"content\":\"1200\"}],[\"$\",\"meta\",\"7\",{\"property\":\"og:image:height\",\"content\":\"630\"}],[\"$\",\"meta\",\"8\",{\"property\":\"og:type\",\"content\":\"article\"}],[\"$\",\"meta\",\"9\",{\"property\":\"article:published_time\",\"content\":\"2024-08-28T20:24:25.000+00:00\"}],[\"$\",\"meta\",\"10\",{\"property\":\"article:author\",\"content\":\"Causely\"}],[\"$\",\"meta\",\"11\",{\"name\":\"twitter:card\",\"content\":\"summary_large_image\"}],[\"$\",\"meta\",\"12\",{\"name\":\"twitter:title\",\"content\":\"Preventing Out-of-Memory (OOM) Kills in Kubernetes: Tips for Optimizing Container Memory Management\"}],[\"$\",\"meta\",\"13\",{\"name\":\"twitter:description\",\"content\":\"Running containerized applications at scale with Kubernetes demands careful resource management. One very complicated but common challenge is preventing Out-of-Memory (OOM) kills, which occur when a container’s memory consumption surpasses its allocated limit. This brutal termination by the Kubernet\"}],[\"$\",\"meta\",\"14\",{\"name\":\"twitter:image\",\"content\":\"https://storage.ghost.io/c/f4/30/f4302d25-b539-4f59-b4cb-e3882f8f5026/content/images/wp-content/uploads/2024/08/preventing-oom-kills-1.png\"}],[\"$\",\"link\",\"15\",{\"rel\":\"icon\",\"href\":\"/favicon.ico\",\"sizes\":\"any\"}],[\"$\",\"link\",\"16\",{\"rel\":\"apple-touch-icon\",\"href\":\"/apple-touch-icon.png\",\"sizes\":\"180x180\"}],[\"$\",\"$L2d\",\"17\",{}]]\n2e:I[10333,[\"/_next/static/immutable/chunks/011me_93942kq.js\",\"/_next/static/immutable/chunks/1c_nr-0i0gjnt.js\",\"/_next/static/immutable/chunks/3lgnztd7blcu2.js\",\"/_next/static/immutable/chunks/17dj4bkkdjper.js\",\"/_next/static/immutable/chunks/0vbcyr25-edwj.js\",\"/_next/static/immutable/chunks/2-s-9-xpk6j_j.js\",\"/_next/static/immutable/chunks/0ojqgjv--k_a7.js\",\"/_next/static/immutable/chunks/3cxalgnb-xm18.js\",\"/_next/static/immutable/chunks/3ithhqp6kca4w.js\"],\"AnimatedText\"]\n2c:[\"$\",\"section\",null,{\"className\":\"bg-main-background py-0 overflow-hidden px-6 md:px-6 xl:px-[104px] 3xl:px-[284px] pb-[107px] md:pb-[143px] xl:pb-[178px] 3xl:pb-[200px]\",\"children\":[\"$\",\"div\",null,{\"className\":\"mx-auto max-w-[1280px] px-0 3xl:max-w-[776px]\",\"children\":[\"$\",\"div\",null,{\"className\":\"flex flex-col gap-6 md:gap-6 3xl:gap-[24px] items-center justify-center px-0 md:px-12 3xl:pl-[48px] 3xl:pr-[40px] 3xl:pt-0 rounded-[32px]\",\"children\":[[\"$\",\"div\",null,{\"className\":\"bg-main-background flex flex-col gap-[3.367px] items-start overflow-hidden relative\",\"children\":[\"$\",\"div\",null,{\"className\":\"relative h-[267.418px] w-[352px] md:h-[277px] md:w-[352px] 3xl:h-[378px] 3xl:w-[542px]\",\"children\":[\"$\",\"$L8\",null,{\"src\":\"/images/home-cta/cta-decoration.webp\",\"alt\":\"\",\"fill\":true,\"className\":\"object-contain\",\"sizes\":\"(max-width: 1919px) 352px, 542px\"}]}]}],[\"$\",\"div\",null,{\"className\":\"flex flex-col gap-7 md:gap-[28px] 3xl:gap-[32px] items-center md:items-center 3xl:items-center justify-center w-full\",\"children\":[[\"$\",\"div\",null,{\"className\":\"flex flex-col gap-3 md:gap-3 3xl:gap-[12px] items-start md:items-center justify-center text-center w-full\",\"children\":[[\"$\",\"$L2e\",null,{\"as\":\"h3\",\"className\":\"font-general-sans text-[28px] md:text-[28px] 3xl:text-[48px] font-medium leading-[1.1] text-white-custom mx-auto\",\"children\":[\"Your agents are ready. \",[\"$\",\"span\",null,{\"className\":\"block\",\"children\":\"Give them the context to act.\"}]]}],[\"$\",\"div\",null,{\"className\":\"flex flex-col font-inter text-sm md:text-base 3xl:text-lg font-normal text-grey leading-[normal] md:leading-[1.2] xl:leading-[1.45] w-full max-w-full md:max-w-[388px] 3xl:max-w-[438px]\",\"children\":[\"$\",\"$L2e\",null,{\"as\":\"p\",\"className\":\"mb-0\",\"children\":\"Causely is the missing layer between your observability data and autonomous operations.\"}]}]]}],[\"$\",\"div\",null,{\"className\":\"flex gap-3 justify-center w-full\",\"children\":[[\"$\",\"$L19\",null,{\"href\":\"/try\",\"className\":\"whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group items-center relative flex-1 flex justify-end\",\"children\":[[\"$\",\"div\",null,{\"className\":\"rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden bg-[linear-gradient(to_right,#07bc85_0%,#8dfcdb_90%,#8dfcdb_100%)] relative z-10 lg:mr-[-5px]\",\"children\":[\"$\",\"span\",null,{\"className\":\"font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-black\",\"children\":\"Talk to us\"}]}],[\"$\",\"div\",null,{\"className\":\"relative overflow-hidden -ml-[5px] z-10 bg-causely-green-300 rounded-full p-4 w-[52px] h-[52px] items-center justify-center transition-all duration-200 ease-out hidden md:flex\",\"children\":[[\"$\",\"$L8\",null,{\"src\":\"/images/icons/dotted-arrow.svg\",\"alt\":\"Arrow\",\"width\":20,\"height\":20,\"className\":\"w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out lg:group-hover:translate-x-[200%]\"}],[\"$\",\"$L8\",null,{\"src\":\"/images/icons/dotted-arrow.svg\",\"alt\":\"Arrow\",\"width\":20,\"height\":20,\"className\":\"hidden lg:block absolute w-5 h-5 lg:transition-all lg:duration-200 lg:ease-out opacity-0 -translate-x-[200%] lg:group-hover:opacity-100 lg:group-hover:translate-x-0\"}]]}]]}],[\"$\",\"a\",null,{\"href\":\"https://auth.causely.app/oauth/account/sign-up\",\"target\":\"_self\",\"rel\":\"$undefined\",\"className\":\"whitespace-nowrap text-base font-medium font-general-sans transition-all duration-300 ease-in-out focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 group items-center relative flex-1 flex justify-start\",\"children\":\"$L2f\"}]]}]]}]]}]}]}]\n2f:[[\"$\",\"div\",null,{\"className\":\"rounded-full px-[33px] h-[48px] flex items-center transition-all duration-300 ease-in-out overflow-hidden border border-white-custom group-hover:border-causely-green\",\"children\":[\"$\",\"span\",null,{\"className\":\"font-general-sans font-medium text-base leading-[1.001] transition-all duration-300 ease-in-out text-white-custom group-hover:text-causely-green\",\"children\":\"Try now\"}]}],\"$undefined\"]\n"])</script></body></html>