{"id":55650,"date":"2026-11-26T14:14:09","date_gmt":"2026-11-26T14:14:09","guid":{"rendered":"https:\/\/accuweb.cloud\/resource\/?post_type=cs_article&#038;p=55650"},"modified":"2026-11-26T14:14:09","modified_gmt":"2026-11-26T14:14:09","slug":"docker-container-exited-with-code-137-is-it-really-out-of-memory","status":"publish","type":"cs_article","link":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory","title":{"rendered":"Docker Container Exited with Code 137: Is It Really Out of Memory?"},"content":{"rendered":"<h1 class=\"ack-h1\" style=\"text-align: left;\"><b>Docker Container Exited with Code 137: Is It Really Out of Memory?<\/b><\/h1>\n<p><span style=\"font-weight: 400;\">You run <a href=\"https:\/\/accuweb.cloud\/application\/docker-hosting\"><strong>docker<\/strong><\/a> ps -a and see <\/span><b>Exited (137)<\/b><span style=\"font-weight: 400;\"> next to your container. Most guides say it is an out of memory problem and stop there. That is only one of the possible causes. If you raise the memory limit when memory was not the problem, the container will keep dying.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">This guide shows how to find the real cause in a few minutes and how to fix it.<\/span><\/p>\n<h2 class=\"ack-h2\"><b>What Does Exit Code 137 Mean?<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Exit code 137 is 128 + 9. The 9 is the <\/span><b>SIGKILL<\/b><span style=\"font-weight: 400;\"> signal, which stops a process at once and cannot be ignored. So <\/span><b>137 only tells you that something killed the main process of the container<\/b><span style=\"font-weight: 400;\">. Docker reports the result, not who did it.<\/span><\/p>\n<table>\n<tbody>\n<tr>\n<td><b>Cause<\/b><\/td>\n<td><b>What to check<\/b><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">The container reached its own memory limit<\/span><\/td>\n<td><span style=\"font-weight: 400;\">OOMKilled=true and a &#8220;Memory cgroup out of memory&#8221; line in the kernel log<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">The whole server ran out of memory<\/span><\/td>\n<td><span style=\"font-weight: 400;\">An &#8220;Out of memory: Killed process&#8221; line in the kernel log<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">docker stop timed out, or docker kill was used<\/span><\/td>\n<td><span style=\"font-weight: 400;\">OOMKilled=false and no memory lines in the kernel log<\/span><\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">Someone or something ran kill -9, such as a script or an orchestrator<\/span><\/td>\n<td><span style=\"font-weight: 400;\">Your shell history, scripts and health checks<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><span style=\"font-weight: 400;\">The steps below go from the quickest check to the slowest. Replace oom-demo with your own container name.<\/span><br \/>\n<!-- CTA 3 --><\/p>\n<div class=\"acc-blog-button\">\n<div style=\"text-align: center;\">\n<div class=\"ack-cta-button\"><a href=\"https:\/\/manage.accuweb.cloud\/register?utm_source=blog&amp;utm_medium=cta&amp;utm_campaign=docker_exit_code_137\" target=\"_blank\" rel=\"noopener\"><b>Register for Secure VPS Backups \u00bb<\/b><\/a><\/div>\n<\/div>\n<\/div>\n<div class=\"article-space\"><\/div>\n<h2 class=\"ack-h2\"><b>Step 1: Confirm the Exit Code<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">List the container and its status:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker ps -a &#8211;filter name=oom-demo &#8211;format &#8220;table {{.Names}}\\t{{.Status}}&#8221;<\/span><\/p>\n<p><img fetchpriority=\"high\" decoding=\"async\" class=\"alignnone size-full wp-image-55657\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png\" alt=\"Check the OOMKilled Flag\" width=\"1206\" height=\"258\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3-300x64.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3-1024x219.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3-768x164.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><b>Expected result:<\/b><span style=\"font-weight: 400;\"> the Status column shows Exited (137).<\/span><\/p>\n<h2 class=\"ack-h2\"><b>Step 2: Check the OOMKilled Flag<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Ask Docker whether the kernel killed the container for memory:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker inspect -f &#8216;ExitCode={{.State.ExitCode}} OOMKilled={{.State.OOMKilled}}&#8217; oom-demo<\/span><\/p>\n<p><img decoding=\"async\" class=\"alignnone size-full wp-image-55655\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-5-3.png\" alt=\"Check Docker Events\" width=\"1206\" height=\"229\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-5-3.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-5-3-300x57.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-5-3-1024x194.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-5-3-768x146.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><b>Expected result: <\/b><span style=\"font-weight: 400;\">ExitCode=137 OOMKilled=true confirms that the kernel&#8217;s out of memory killer ended the main process of the container. It does not yet tell you why memory ran out. The container may have reached its own limit, or the whole server may have run short of memory. Go to Step 3 to find out which. If it says OOMKilled=false, do not stop here. Go to Step 3 as well.<\/span><\/p>\n<h2 class=\"ack-h2\"><b>Step 3: Read the Kernel Log<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">The kernel writes a line every time it kills a process for memory:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">dmesg -T | grep -i -E &#8220;out of memory|killed process&#8221; | tail -n 3<\/span><\/p>\n<p><img decoding=\"async\" class=\"alignnone size-full wp-image-55654\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-6-3.png\" alt=\" Rule Out a Stop or a Kill\" width=\"1206\" height=\"286\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-6-3.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-6-3-300x71.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-6-3-1024x243.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-6-3-768x182.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><span style=\"font-weight: 400;\">Two messages matter:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><b>Memory cgroup out of memory:<\/b><span style=\"font-weight: 400;\"> the container reached its own limit. Go to Fix 1.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><b>Out of memory: Killed process:<\/b><span style=\"font-weight: 400;\"> the whole server ran out of memory and the kernel picked a victim, which may have been your container. The container limit is not the cause. Go to Fix 2.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">If you see no lines, do not rule out memory yet. The kernel log is cleared after a reboot, old lines are pushed out as new messages arrive, and some systems keep kernel messages only in the system journal, so check there too. If the OOMKilled flag from Step 2 or the Docker event from Step 4 shows an out of memory kill, treat it as one even when the kernel log is empty. Only when all three show nothing, go to Step 5.<\/span><\/p>\n<h2 class=\"ack-h2\"><b>Step 4: Check Docker Events (Optional)<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Docker keeps its own record of out of memory kills:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker events &#8211;since 15m &#8211;until &#8220;$(date +%s)&#8221; &#8211;filter event=oom<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55658\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-2-3.png\" alt=\"Confirm the Exit Code\" width=\"1206\" height=\"258\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-2-3.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-2-3-300x64.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-2-3-1024x219.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-2-3-768x164.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p><b>Expected result:<\/b><span style=\"font-weight: 400;\"> one container oom line with your container name and a time. It confirms the Step 2 and Step 3 findings.<\/span><br \/>\n<!-- CTA 4 --><\/p>\n<div class=\"acc-blog-button\">\n<div style=\"text-align: center;\">\n<div class=\"ack-cta-button\"><a href=\"https:\/\/manage.accuweb.cloud\/register?utm_source=blog&amp;utm_medium=cta&amp;utm_campaign=docker_exit_code_137\" target=\"_blank\" rel=\"noopener\"><b>Register Now to Deploy Docker \u00bb<\/b><\/a><\/div>\n<\/div>\n<\/div>\n<div class=\"article-space\"><\/div>\n<h2 class=\"ack-h2\"><b>Step 5: Rule Out a Stop or a Kill<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">If OOMKilled is false and the kernel log is clean, the main process was killed on purpose or by a timeout. docker stop sends SIGTERM, waits 10 seconds, then sends SIGKILL. <\/span><b>If your app ignores SIGTERM, the container always ends with 137 after about 10 seconds.<\/b><span style=\"font-weight: 400;\"> This example container ignores SIGTERM:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker run -d &#8211;name stubborn alpine sh -c &#8216;trap &#8220;&#8221; TERM; while true; do sleep 1; done&#8217;<\/span><\/p>\n<p><span style=\"font-weight: 400;\">time docker stop stubborn<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker inspect -f &#8216;ExitCode={{.State.ExitCode}} OOMKilled={{.State.OOMKilled}}&#8217; stubborn<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55656\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-4-3.png\" alt=\"Read the Kernel Log\" width=\"1206\" height=\"486\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-4-3.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-4-3-300x121.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-4-3-1024x413.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-4-3-768x309.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><b>Expected result:<\/b><span style=\"font-weight: 400;\"> docker stop takes about 10 seconds, then you see ExitCode=137 OOMKilled=false. The command docker kill gives the same result right away:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker run -d &#8211;name killed alpine sleep 600<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker kill killed<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker inspect -f &#8216;ExitCode={{.State.ExitCode}} OOMKilled={{.State.OOMKilled}}&#8217; killed<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55651\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-11-1.png\" alt=\"Expected result\" width=\"1206\" height=\"343\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-11-1.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-11-1-300x85.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-11-1-1024x291.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-11-1-768x218.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><span style=\"font-weight: 400;\">If nobody ran docker stop or docker kill, check your scripts, CI jobs and any orchestrator health checks that restart containers.<\/span><\/p>\n<p><!-- CTA 2 --><\/p>\n<div class=\"acc-blog-button\">\n<div style=\"text-align: center;\">\n<div class=\"ack-cta-button\"><a href=\"https:\/\/manage.accuweb.cloud\/register?utm_source=blog&amp;utm_medium=cta&amp;utm_campaign=docker_exit_code_137\" target=\"_blank\" rel=\"noopener\"><b>Register for Dedicated vCPU and RAM \u00bb<\/b><\/a><\/div>\n<\/div>\n<\/div>\n<div class=\"article-space\"><\/div>\n<h2 class=\"ack-h2\"><b>How to Fix It<\/b><\/h2>\n<h3><b>Fix 1: The Container Hit Its Memory Limit<\/b><\/h3>\n<ol>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Watch the real usage with docker stats and compare it with the limit.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Raise the limit: docker run -m 256m &#8230;, or mem_limit: 256m in a Compose file.<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">If memory keeps growing, look for a leak or a large cache in the app. Set the app&#8217;s own cap below the container limit, for example -XX:MaxRAMPercentage for Java or &#8211;max-old-space-size for Node.js.<\/span><\/li>\n<\/ol>\n<h3><b>Fix 2: The Whole Server Ran Out of Memory<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">A container without a limit can use all the memory of the host. <\/span><b>Set a memory limit on every container<\/b><span style=\"font-weight: 400;\"> so one of them cannot starve the others, and check the host with free -h. If the server is simply too small, move to a plan with more RAM. On an AccuWeb.Cloud VPS the vCPU and RAM are dedicated, and you can scale up later by adding RAM.<\/span><\/p>\n<h3><b>Fix 3: The Container Ignores SIGTERM<\/b><\/h3>\n<p><span style=\"font-weight: 400;\">Make the app handle SIGTERM and shut down cleanly. If you cannot change the app, you can start the container with Docker&#8217;s init option. It runs a small init process that passes signals on to your app, which helps when the app misses SIGTERM only because of how it is started. The init option cannot fix an application that receives SIGTERM and deliberately ignores it. An app like the one in Step 5 would still be killed after the 10 second timeout. For that case, change the app, or give the stop request more time.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker run -d &#8211;name polite &#8211;init alpine sleep 600<\/span><\/p>\n<p><span style=\"font-weight: 400;\">time docker stop polite<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker inspect -f &#8216;ExitCode={{.State.ExitCode}} OOMKilled={{.State.OOMKilled}}&#8217; polite<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55653\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-7-2.png\" alt=\"docker inspect\" width=\"1206\" height=\"457\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-7-2.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-7-2-300x114.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-7-2-1024x388.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-7-2-768x291.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><b>Expected result: <\/b><span style=\"font-weight: 400;\">this test container does not handle SIGTERM itself. With the init option it stops in about a second, and the exit code is 143 (128 plus 15, SIGTERM) instead of 137.<\/span><\/p>\n<h2 class=\"ack-h2\"><b>Verify the Fix<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Run the same workload that crashed with a bigger limit, and check that it stays up:<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker run -d &#8211;name ok-demo -m 256m python:3-alpine python -c &#8220;import time; a=[chr(32)*10**6 for _ in range(100)]; time.sleep(600)&#8221;<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker stats &#8211;no-stream ok-demo<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker ps &#8211;filter name=ok-demo &#8211;format &#8220;table {{.Names}}\\t{{.Status}}&#8221;<\/span><\/p>\n<p><span style=\"font-weight: 400;\">docker inspect -f &#8216;ExitCode={{.State.ExitCode}} OOMKilled={{.State.OOMKilled}}&#8217; ok-demo<\/span><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-55652\" src=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-9-1.png\" alt=\"docker run\" width=\"1206\" height=\"571\" srcset=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-9-1.png 1206w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-9-1-300x142.png 300w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-9-1-1024x485.png 1024w, https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-9-1-768x364.png 768w\" sizes=\"(max-width: 1206px) 100vw, 1206px\" \/><\/p>\n<p><b>Expected result:<\/b><span style=\"font-weight: 400;\"> the container shows Up, memory use is well below the 256 MiB limit, and the last line shows OOMKilled=false.<\/span><\/p>\n<h2 class=\"ack-h2\"><b>Conclusion<\/b><\/h2>\n<p><span style=\"font-weight: 400;\">Exit code 137 means SIGKILL, not always out of memory. Check the OOMKilled flag first, then the kernel log, and only then look at stops and kills. Fix the cause you actually found, and set a memory limit on every container.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Before you change limits on a production server, take a snapshot or backup so you can roll back. AccuWeb.Cloud backup services can do this for your VPS. For more on managing Docker, read our guide on connecting to Docker Engine and managing it.<\/span><\/p>\n<p><!-- CTA 1 --><\/p>\n<div class=\"acc-blog-button\">\n<div style=\"text-align: center;\">\n<div class=\"ack-cta-button\"><a href=\"https:\/\/manage.accuweb.cloud\/register?utm_source=blog&amp;utm_medium=cta&amp;utm_campaign=docker_exit_code_137\" target=\"_blank\" rel=\"noopener\"><b>Register to Deploy Docker with More RAM \u00bb<\/b><\/a><\/div>\n<\/div>\n<\/div>\n<div class=\"article-space\"><\/div>\n","protected":false},"excerpt":{"rendered":"<div class='heateorSssClear'><\/div><div  class='heateor_sss_sharing_container heateor_sss_horizontal_sharing' data-heateor-sss-href='https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory'><div class='heateor_sss_sharing_title' style=\"font-weight:bold\" ><\/div><div class=\"heateor_sss_sharing_ul\"><a aria-label=\"Facebook\" class=\"heateor_sss_facebook\" href=\"https:\/\/www.facebook.com\/sharer\/sharer.php?u=https%3A%2F%2Faccuweb.cloud%2Fresource%2Fcs%2Fdocker-container-exited-with-code-137-is-it-really-out-of-memory\" title=\"Facebook\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg\" style=\"background-color:#0765FE;width:30px;height:30px;border-radius:999px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg style=\"display:block;border-radius:999px;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"100%\" height=\"100%\" viewBox=\"0 0 32 32\"><path fill=\"#000\" d=\"M28 16c0-6.627-5.373-12-12-12S4 9.373 4 16c0 5.628 3.875 10.35 9.101 11.647v-7.98h-2.474V16H13.1v-1.58c0-4.085 1.849-5.978 5.859-5.978.76 0 2.072.15 2.608.298v3.325c-.283-.03-.775-.045-1.386-.045-1.967 0-2.728.745-2.728 2.683V16h3.92l-.673 3.667h-3.247v8.245C23.395 27.195 28 22.135 28 16Z\"><\/path><\/svg><\/span><\/a><a aria-label=\"X\" class=\"heateor_sss_button_x\" href=\"https:\/\/twitter.com\/intent\/tweet?text=Docker%20Container%20Exited%20with%20Code%20137%3A%20Is%20It%20Really%20Out%20of%20Memory%3F&url=https%3A%2F%2Faccuweb.cloud%2Fresource%2Fcs%2Fdocker-container-exited-with-code-137-is-it-really-out-of-memory\" title=\"X\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg heateor_sss_s__default heateor_sss_s_x\" style=\"background-color:#2a2a2a;width:30px;height:30px;border-radius:999px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg width=\"100%\" height=\"100%\" style=\"display:block;border-radius:999px;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 32 32\"><path fill=\"#000\" d=\"M21.751 7h3.067l-6.7 7.658L26 25.078h-6.172l-4.833-6.32-5.531 6.32h-3.07l7.167-8.19L6 7h6.328l4.37 5.777L21.75 7Zm-1.076 16.242h1.7L11.404 8.74H9.58l11.094 14.503Z\"><\/path><\/svg><\/span><\/a><a aria-label=\"Linkedin\" class=\"heateor_sss_button_linkedin\" href=\"https:\/\/www.linkedin.com\/sharing\/share-offsite\/?url=https%3A%2F%2Faccuweb.cloud%2Fresource%2Fcs%2Fdocker-container-exited-with-code-137-is-it-really-out-of-memory\" title=\"Linkedin\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg heateor_sss_s__default heateor_sss_s_linkedin\" style=\"background-color:#0077b5;width:30px;height:30px;border-radius:999px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg style=\"display:block;border-radius:999px;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"100%\" height=\"100%\" viewBox=\"0 0 32 32\"><path d=\"M6.227 12.61h4.19v13.48h-4.19V12.61zm2.095-6.7a2.43 2.43 0 0 1 0 4.86c-1.344 0-2.428-1.09-2.428-2.43s1.084-2.43 2.428-2.43m4.72 6.7h4.02v1.84h.058c.56-1.058 1.927-2.176 3.965-2.176 4.238 0 5.02 2.792 5.02 6.42v7.395h-4.183v-6.56c0-1.564-.03-3.574-2.178-3.574-2.18 0-2.514 1.7-2.514 3.46v6.668h-4.187V12.61z\" fill=\"#000\"><\/path><\/svg><\/span><\/a><a aria-label=\"Whatsapp\" class=\"heateor_sss_whatsapp\" href=\"https:\/\/api.whatsapp.com\/send?text=Docker%20Container%20Exited%20with%20Code%20137%3A%20Is%20It%20Really%20Out%20of%20Memory%3F%20https%3A%2F%2Faccuweb.cloud%2Fresource%2Fcs%2Fdocker-container-exited-with-code-137-is-it-really-out-of-memory\" title=\"Whatsapp\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg\" style=\"background-color:#55eb4c;width:30px;height:30px;border-radius:999px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg style=\"display:block;border-radius:999px;\" focusable=\"false\" aria-hidden=\"true\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"100%\" height=\"100%\" viewBox=\"-6 -5 40 40\"><path class=\"heateor_sss_svg_stroke heateor_sss_no_fill\" stroke=\"#000\" stroke-width=\"2\" fill=\"none\" d=\"M 11.579798566743314 24.396926207859085 A 10 10 0 1 0 6.808479557110079 20.73576436351046\"><\/path><path d=\"M 7 19 l -1 6 l 6 -1\" class=\"heateor_sss_no_fill heateor_sss_svg_stroke\" stroke=\"#000\" stroke-width=\"2\" fill=\"none\"><\/path><path d=\"M 10 10 q -1 8 8 11 c 5 -1 0 -6 -1 -3 q -4 -3 -5 -5 c 4 -2 -1 -5 -1 -4\" fill=\"#000\"><\/path><\/svg><\/span><\/a><a aria-label=\"Instagram\" class=\"heateor_sss_button_instagram\" href=\"https:\/\/www.instagram.com\/\" title=\"Instagram\" rel=\"nofollow noopener\" target=\"_blank\" style=\"font-size:32px!important;box-shadow:none;display:inline-block;vertical-align:middle\"><span class=\"heateor_sss_svg\" style=\"background-color:#53beee;width:30px;height:30px;border-radius:999px;display:inline-block;opacity:1;float:left;font-size:32px;box-shadow:none;display:inline-block;font-size:16px;padding:0 4px;vertical-align:middle;background-repeat:repeat;overflow:hidden;padding:0;cursor:pointer;box-sizing:content-box\"><svg style=\"display:block;border-radius:999px;\" version=\"1.1\" viewBox=\"-10 -10 148 148\" width=\"100%\" height=\"100%\" xml:space=\"preserve\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" xmlns:xlink=\"http:\/\/www.w3.org\/1999\/xlink\"><g><g><path d=\"M86,112H42c-14.336,0-26-11.663-26-26V42c0-14.337,11.664-26,26-26h44c14.337,0,26,11.663,26,26v44 C112,100.337,100.337,112,86,112z M42,24c-9.925,0-18,8.074-18,18v44c0,9.925,8.075,18,18,18h44c9.926,0,18-8.075,18-18V42 c0-9.926-8.074-18-18-18H42z\" fill=\"#000\"><\/path><\/g><g><path d=\"M64,88c-13.234,0-24-10.767-24-24c0-13.234,10.766-24,24-24s24,10.766,24,24C88,77.233,77.234,88,64,88z M64,48c-8.822,0-16,7.178-16,16s7.178,16,16,16c8.822,0,16-7.178,16-16S72.822,48,64,48z\" fill=\"#000\"><\/path><\/g><g><circle cx=\"89.5\" cy=\"38.5\" fill=\"#000\" r=\"5.5\"><\/circle><\/g><\/g><\/svg><\/span><\/a><\/div><div class=\"heateorSssClear\"><\/div><\/div><div class='heateorSssClear'><\/div><p>Docker Container Exited with Code 137: Is It Really Out of Memory? You run docker ps -a and see Exited (137) next to your container. Most guides say it is an out of memory problem and stop there. That is only one of the possible causes. If you raise the memory limit when memory was [&hellip;]<\/p>\n","protected":false},"featured_media":0,"template":"","meta":[],"cs_category":[1010,1027],"class_list":["post-55650","cs_article","type-cs_article","status-publish","hentry","cs_category-cs-articles","cs_category-docker"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v20.10 (Yoast SEO v24.5) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Docker Exit Code 137: Is It Really Out of Memory?<\/title>\n<meta name=\"description\" content=\"Exit code 137 in Docker is not always out of memory. Learn how to check the OOMKilled flag, read kernel logs, rule out SIGKILL, and fix the real cause fast.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Docker Container Exited with Code 137: Is It Really Out of Memory?\" \/>\n<meta property=\"og:description\" content=\"Exit code 137 in Docker is not always out of memory. Learn how to check the OOMKilled flag, read kernel logs, rule out SIGKILL, and fix the real cause fast.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory\" \/>\n<meta property=\"og:site_name\" content=\"AccuWeb Cloud\" \/>\n<meta property=\"og:image\" content=\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1206\" \/>\n\t<meta property=\"og:image:height\" content=\"258\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"7 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory\",\"url\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory\",\"name\":\"Docker Exit Code 137: Is It Really Out of Memory?\",\"isPartOf\":{\"@id\":\"https:\/\/accuweb.cloud\/resource\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#primaryimage\"},\"image\":{\"@id\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#primaryimage\"},\"thumbnailUrl\":\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png\",\"datePublished\":\"2026-11-26T14:14:09+00:00\",\"description\":\"Exit code 137 in Docker is not always out of memory. Learn how to check the OOMKilled flag, read kernel logs, rule out SIGKILL, and fix the real cause fast.\",\"breadcrumb\":{\"@id\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#primaryimage\",\"url\":\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png\",\"contentUrl\":\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png\",\"width\":1206,\"height\":258,\"caption\":\"Check the OOMKilled Flag\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/accuweb.cloud\/resource\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"CS Articles\",\"item\":\"https:\/\/accuweb.cloud\/resource\/cs\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Docker Container Exited with Code 137: Is It Really Out of Memory?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/accuweb.cloud\/resource\/#website\",\"url\":\"https:\/\/accuweb.cloud\/resource\/\",\"name\":\"AccuWeb Cloud\",\"description\":\"Cutting Edge Cloud Computing\",\"publisher\":{\"@id\":\"https:\/\/accuweb.cloud\/resource\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/accuweb.cloud\/resource\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/accuweb.cloud\/resource\/#organization\",\"name\":\"AccuWeb.Cloud\",\"url\":\"https:\/\/accuweb.cloud\/resource\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/accuweb.cloud\/resource\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2024\/04\/accuwebcloud_logo_black_tagline.jpg\",\"contentUrl\":\"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2024\/04\/accuwebcloud_logo_black_tagline.jpg\",\"width\":156,\"height\":87,\"caption\":\"AccuWeb.Cloud\"},\"image\":{\"@id\":\"https:\/\/accuweb.cloud\/resource\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Docker Exit Code 137: Is It Really Out of Memory?","description":"Exit code 137 in Docker is not always out of memory. Learn how to check the OOMKilled flag, read kernel logs, rule out SIGKILL, and fix the real cause fast.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory","og_locale":"en_US","og_type":"article","og_title":"Docker Container Exited with Code 137: Is It Really Out of Memory?","og_description":"Exit code 137 in Docker is not always out of memory. Learn how to check the OOMKilled flag, read kernel logs, rule out SIGKILL, and fix the real cause fast.","og_url":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory","og_site_name":"AccuWeb Cloud","og_image":[{"width":1206,"height":258,"url":"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png","type":"image\/png"}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"7 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory","url":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory","name":"Docker Exit Code 137: Is It Really Out of Memory?","isPartOf":{"@id":"https:\/\/accuweb.cloud\/resource\/#website"},"primaryImageOfPage":{"@id":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#primaryimage"},"image":{"@id":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#primaryimage"},"thumbnailUrl":"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png","datePublished":"2026-11-26T14:14:09+00:00","description":"Exit code 137 in Docker is not always out of memory. Learn how to check the OOMKilled flag, read kernel logs, rule out SIGKILL, and fix the real cause fast.","breadcrumb":{"@id":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#primaryimage","url":"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png","contentUrl":"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2026\/11\/gdoc-image-3-3.png","width":1206,"height":258,"caption":"Check the OOMKilled Flag"},{"@type":"BreadcrumbList","@id":"https:\/\/accuweb.cloud\/resource\/cs\/docker-container-exited-with-code-137-is-it-really-out-of-memory#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/accuweb.cloud\/resource\/"},{"@type":"ListItem","position":2,"name":"CS Articles","item":"https:\/\/accuweb.cloud\/resource\/cs"},{"@type":"ListItem","position":3,"name":"Docker Container Exited with Code 137: Is It Really Out of Memory?"}]},{"@type":"WebSite","@id":"https:\/\/accuweb.cloud\/resource\/#website","url":"https:\/\/accuweb.cloud\/resource\/","name":"AccuWeb Cloud","description":"Cutting Edge Cloud Computing","publisher":{"@id":"https:\/\/accuweb.cloud\/resource\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/accuweb.cloud\/resource\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/accuweb.cloud\/resource\/#organization","name":"AccuWeb.Cloud","url":"https:\/\/accuweb.cloud\/resource\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/accuweb.cloud\/resource\/#\/schema\/logo\/image\/","url":"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2024\/04\/accuwebcloud_logo_black_tagline.jpg","contentUrl":"https:\/\/accuweb.cloud\/resource\/wp-content\/uploads\/2024\/04\/accuwebcloud_logo_black_tagline.jpg","width":156,"height":87,"caption":"AccuWeb.Cloud"},"image":{"@id":"https:\/\/accuweb.cloud\/resource\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/accuweb.cloud\/resource\/wp-json\/wp\/v2\/cs_article\/55650","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/accuweb.cloud\/resource\/wp-json\/wp\/v2\/cs_article"}],"about":[{"href":"https:\/\/accuweb.cloud\/resource\/wp-json\/wp\/v2\/types\/cs_article"}],"wp:attachment":[{"href":"https:\/\/accuweb.cloud\/resource\/wp-json\/wp\/v2\/media?parent=55650"}],"wp:term":[{"taxonomy":"cs_category","embeddable":true,"href":"https:\/\/accuweb.cloud\/resource\/wp-json\/wp\/v2\/cs_category?post=55650"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}