{"id":4239,"date":"2019-09-11T17:15:10","date_gmt":"2019-09-11T14:15:10","guid":{"rendered":"https:\/\/www.systemcodegeeks.com\/?p=4239"},"modified":"2019-09-11T11:32:14","modified_gmt":"2019-09-11T08:32:14","slug":"tcp-out-of-memory-consider-tuning-tcp_mem","status":"publish","type":"post","link":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/","title":{"rendered":"TCP: out of memory \u2014 consider tuning tcp_mem"},"content":{"rendered":"\n<p>Recently we experienced an interesting production problem. This application was running on multiple AWS EC2 instances behind Elastic Load Balancer. The application was running on GNU\/Linux OS, Java 8, Tomcat 8 application server. All of sudden one of the application instances became unresponsive. All other application instances were handling the traffic properly. Whenever the HTTP request was sent to this application instance from the browser, we were getting following response to be printed on the browser.<\/p>\n\n\n\n<div>\n<div id=\"highlighter_853685\" class=\"syntaxhighlighter  php\">\n<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\n<tbody>\n<tr>\n<td class=\"gutter\">\n<div class=\"line number1 index0 alt2\">1<\/div>\n<div class=\"line number2 index1 alt1\">2<\/div>\n<div class=\"line number3 index2 alt2\">3<\/div>\n<div class=\"line number4 index3 alt1\">4<\/div>\n<div class=\"line number5 index4 alt2\">5<\/div>\n<div class=\"line number6 index5 alt1\">6<\/div>\n<\/td>\n<td class=\"code\">\n<div class=\"container\">\n<div class=\"line number1 index0 alt2\"><code class=\"php plain\">Proxy Error <\/code><\/div>\n<div class=\"line number2 index1 alt1\">&nbsp;<\/div>\n<div class=\"line number3 index2 alt2\"><code class=\"php plain\">The proxy server received an invalid response from an upstream server. <\/code><\/div>\n<div class=\"line number4 index3 alt1\"><code class=\"php plain\">The proxy server could not handle the request GET \/.<\/code><\/div>\n<div class=\"line number5 index4 alt2\">&nbsp;<\/div>\n<div class=\"line number6 index5 alt1\"><code class=\"php plain\">Reason: Error reading from remote server<\/code><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n\n\n\n<p>We used our APM (Application Performance Monitoring) tool to examine the problem. From the APM tool, we could observe CPU, memory utilization to be perfect. On the other hand, from the APM tool, we could observe that traffic wasn\u2019t coming into this particular application instance. It was really puzzling. Why traffic wasn\u2019t coming in?<\/p>\n\n\n\n<p>We logged in to this problematic AWS EC2 instance. We executed <strong>vmstat, iostat, netstat, top, df<\/strong> commands to see whether we can uncover any anomaly. To our surprise, all these great tools didn\u2019t report any issue.<\/p>\n\n\n\n<p>As the next step, we restarted the Tomcat application server in which this application was running. It didn\u2019t make any difference either. Still, this application instance wasn\u2019t responding at all.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">DMESG command<\/h2>\n\n\n\n<p>Then we issued <strong>\u2018dmesg\u2019<\/strong> command on this EC2 instance.&nbsp; This command prints the message buffer of the kernel. The output of this command typically contains the messages produced by the device drivers. In the output generated by this command, we noticed the following interesting messages to be printed repeatedly:<\/p>\n\n\n\n<div>\n<div id=\"highlighter_356619\" class=\"syntaxhighlighter  php\">\n<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\n<tbody>\n<tr>\n<td class=\"gutter\">\n<div class=\"line number1 index0 alt2\">1<\/div>\n<div class=\"line number2 index1 alt1\">2<\/div>\n<div class=\"line number3 index2 alt2\">3<\/div>\n<div class=\"line number4 index3 alt1\">4<\/div>\n<div class=\"line number5 index4 alt2\">5<\/div>\n<div class=\"line number6 index5 alt1\">6<\/div>\n<div class=\"line number7 index6 alt2\">7<\/div>\n<div class=\"line number8 index7 alt1\">8<\/div>\n<div class=\"line number9 index8 alt2\">9<\/div>\n<div class=\"line number10 index9 alt1\">10<\/div>\n<div class=\"line number11 index10 alt2\">11<\/div>\n<div class=\"line number12 index11 alt1\">12<\/div>\n<div class=\"line number13 index12 alt2\">13<\/div>\n<div class=\"line number14 index13 alt1\">14<\/div>\n<div class=\"line number15 index14 alt2\">15<\/div>\n<div class=\"line number16 index15 alt1\">16<\/div>\n<div class=\"line number17 index16 alt2\">17<\/div>\n<div class=\"line number18 index17 alt1\">18<\/div>\n<div class=\"line number19 index18 alt2\">19<\/div>\n<div class=\"line number20 index19 alt1\">20<\/div>\n<div class=\"line number21 index20 alt2\">21<\/div>\n<div class=\"line number22 index21 alt1\">22<\/div>\n<\/td>\n<td class=\"code\">\n<div class=\"container\">\n<div class=\"line number1 index0 alt2\"><code class=\"php plain\">[4486500.513856] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number2 index1 alt1\"><code class=\"php plain\">[4487211.020449] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number3 index2 alt2\"><code class=\"php plain\">[4487369.441522] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number4 index3 alt1\"><code class=\"php plain\">[4487535.908607] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number5 index4 alt2\"><code class=\"php plain\">[4487639.802123] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number6 index5 alt1\"><code class=\"php plain\">[4487717.564383] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number7 index6 alt2\"><code class=\"php plain\">[4487784.382403] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number8 index7 alt1\"><code class=\"php plain\">[4487816.378638] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number9 index8 alt2\"><code class=\"php plain\">[4487855.352405] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number10 index9 alt1\"><code class=\"php plain\">[4487862.816227] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number11 index10 alt2\"><code class=\"php plain\">[4487928.859785] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number12 index11 alt1\"><code class=\"php plain\">[4488215.969409] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number13 index12 alt2\"><code class=\"php plain\">[4488642.426484] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number14 index13 alt1\"><code class=\"php plain\">[4489347.800558] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number15 index14 alt2\"><code class=\"php plain\">[4490054.414047] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number16 index15 alt1\"><code class=\"php plain\">[4490763.997344] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number17 index16 alt2\"><code class=\"php plain\">[4491474.743039] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number18 index17 alt1\"><code class=\"php plain\">[4491859.749745] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number19 index18 alt2\"><code class=\"php plain\">[4492182.082423] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number20 index19 alt1\"><code class=\"php plain\">[4496318.377316] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number21 index20 alt2\"><code class=\"php plain\">[4505666.858267] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<div class=\"line number22 index21 alt1\"><code class=\"php plain\">[4521592.915616] TCP: out of memory -- consider tuning tcp_mem<\/code><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n\n\n\n<p>We were intrigued to see this error message: \u201cTCP: out of memory \u2014 consider tuning tcp_mem\u201d. It means out of memory error is happening at the TCP level. We had always taught out of memory error happens only at the application level and never at the TCP level.<\/p>\n\n\n\n<p>Problem was intriguing because we breathe this OutOfMemoryError problem day in and out. We have built troubleshooting tools like <a href=\"https:\/\/gceasy.io\/\" target=\"_blank\" rel=\"noopener noreferrer\">GCeasy<\/a>, <a href=\"https:\/\/heaphero.io\/\" target=\"_blank\" rel=\"noopener noreferrer\">HeapHero<\/a> to facilitate engineers to debug OutOfMemoryError that happens at the application level (Java, Android, Scala, Jython\u2026 applications). We have written <a href=\"https:\/\/blog.heaphero.io\/?s=OutOfMemoryError\" target=\"_blank\" rel=\"noopener noreferrer\">several blogs on this OutOfMemoryError<\/a> topic. But we were stumped to see OutOfMemory happening at the device driver level. We never thought there would be a problem at the device driver level, that too in, stable Linux operating system. Being stumped by this problem, we weren\u2019t sure how to proceed further.<\/p>\n\n\n\n<p>Thus, we resorted to Google god\u2019s help \ud83d\ude0a. Googling for the search term: \u201cTCP: out of memory \u2014 consider tuning tcp_mem\u201d, showed only 12 search results. But for one article, none of them had much content&nbsp;&nbsp;\u2639. Even that one article was written in a foreign language that we couldn\u2019t understand. So, we aren\u2019t sure how to troubleshoot this problem.<\/p>\n\n\n\n<p>Now left with no other solutions, we went ahead and implemented universal solution i.e. \u201crestart\u201d. We restarted the EC2 instance to put-off immediate burning fire. Hurray!! Restarting the server cleared the problem immediately. Apparently, this server wasn\u2019t restarted for several days (like more than 70+ days), maybe due to that application might have saturated TCP memory limits.<\/p>\n\n\n\n<p>We reached out to one of our intelligent friends who works for a world-class technology company for help. This friend asked us the values that we are setting for the below kernel properties:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>core.netdev_max_backlog<\/li><li>core.rmem_max<\/li><li>core.wmem_max<\/li><li>ipv4.tcp_max_syn_backlog<\/li><li>ipv4.tcp_rmem<\/li><li>net.ipv4.tcp_wmem<\/li><\/ul>\n\n\n\n<p>Honestly, this is the first time, we are hearing about these properties. We found that below are the values set for these properties in the server:<\/p>\n\n\n\n<div>\n<div id=\"highlighter_273038\" class=\"syntaxhighlighter  php\">\n<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\n<tbody>\n<tr>\n<td class=\"gutter\">\n<div class=\"line number1 index0 alt2\">1<\/div>\n<div class=\"line number2 index1 alt1\">2<\/div>\n<div class=\"line number3 index2 alt2\">3<\/div>\n<div class=\"line number4 index3 alt1\">4<\/div>\n<div class=\"line number5 index4 alt2\">5<\/div>\n<div class=\"line number6 index5 alt1\">6<\/div>\n<\/td>\n<td class=\"code\">\n<div class=\"container\">\n<div class=\"line number1 index0 alt2\"><code class=\"php plain\">net.core.netdev_max_backlog = 1000<\/code><\/div>\n<div class=\"line number2 index1 alt1\"><code class=\"php plain\">net.core.rmem_max = 212992<\/code><\/div>\n<div class=\"line number3 index2 alt2\"><code class=\"php plain\">net.core.wmem_max = 212992<\/code><\/div>\n<div class=\"line number4 index3 alt1\"><code class=\"php plain\">net.ipv4.tcp_max_syn_backlog = 256<\/code><\/div>\n<div class=\"line number5 index4 alt2\"><code class=\"php plain\">net.ipv4.tcp_rmem = 4096&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 87380&nbsp;&nbsp; 6291456<\/code><\/div>\n<div class=\"line number6 index5 alt1\"><code class=\"php plain\">net.ipv4.tcp_wmem = 4096&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 20480&nbsp;&nbsp; 4194304<\/code><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n\n\n\n<p>Our friend suggested to change values as given below:<\/p>\n\n\n\n<div>\n<div id=\"highlighter_188790\" class=\"syntaxhighlighter  php\">\n<table border=\"0\" cellspacing=\"0\" cellpadding=\"0\">\n<tbody>\n<tr>\n<td class=\"gutter\">\n<div class=\"line number1 index0 alt2\">1<\/div>\n<div class=\"line number2 index1 alt1\">2<\/div>\n<div class=\"line number3 index2 alt2\">3<\/div>\n<div class=\"line number4 index3 alt1\">4<\/div>\n<div class=\"line number5 index4 alt2\">5<\/div>\n<div class=\"line number6 index5 alt1\">6<\/div>\n<\/td>\n<td class=\"code\">\n<div class=\"container\">\n<div class=\"line number1 index0 alt2\"><code class=\"php plain\">net.core.netdev_max_backlog=30000<\/code><\/div>\n<div class=\"line number2 index1 alt1\"><code class=\"php plain\">net.core.rmem_max=134217728<\/code><\/div>\n<div class=\"line number3 index2 alt2\"><code class=\"php plain\">net.core.wmem_max=134217728<\/code><\/div>\n<div class=\"line number4 index3 alt1\"><code class=\"php plain\">net.ipv4.tcp_max_syn_backlog=8192<\/code><\/div>\n<div class=\"line number5 index4 alt2\"><code class=\"php plain\">net.ipv4.tcp_rmem=4096 87380 67108864<\/code><\/div>\n<div class=\"line number6 index5 alt1\"><code class=\"php plain\">net.ipv4.tcp_wmem=4096 87380 67108864<\/code><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n\n\n\n<p>He mentioned setting these values will eliminate the problem we had faced. Sharing the values with you (as it may be of help to you). Apparently, our values have been very low when compared to the values he has provided.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Conclusion<\/h3>\n\n\n\n<p>Here are a few conclusions that we would like to draw:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>Even the modern industry-standard APM (Application Performance Monitoring) tools aren\u2019t completely answering the application performance problems that we are facing today.<\/li><li>\u2018dmesg\u2019 command is your friend. You might want to execute this command when your application becomes unresponsive, it may point you out valuable information<\/li><li>Memory problems doesn\u2019t have to happen in the code that we write \ud83d\ude0a, it can happen even at the TCP\/Kernel level.<\/li><\/ul>\n\n\n\n<div class=\"attribution\">\n<table>\n<tbody>\n<tr>\n<td>\n<p>Published on System Code Geeks with permission by Ram Lakshmanan, partner at our <a href=\"\/\/www.systemcodegeeks.com\/join-us\/scg\/\" target=\"_blank\" rel=\"noopener noreferrer\">SCG program<\/a>. See the original article here: <a href=\"https:\/\/blog.gceasy.io\/2019\/08\/28\/tcp-out-of-memory-consider-tuning-tcp_mem\/\" target=\"_blank\" rel=\"noopener noreferrer\">TCP: out of memory \u2014 consider tuning tcp_mem<\/a><\/p>\n<p>Opinions expressed by System Code Geeks contributors are their own.<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Recently we experienced an interesting production problem. This application was running on multiple AWS EC2 instances behind Elastic Load Balancer. The application was running on GNU\/Linux OS, Java 8, Tomcat 8 application server. All of sudden one of the application instances became unresponsive. All other application instances were handling the traffic properly. Whenever the HTTP &hellip;<\/p>\n","protected":false},"author":5445,"featured_media":192,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[175,176],"class_list":["post-4239","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","tag-cpu","tag-tcp"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>TCP: out of memory \u2014 consider tuning tcp_mem - System Code Geeks - 2026<\/title>\n<meta name=\"description\" content=\"Interested to learn about AWS EC2 instances? Check our article explaining what to do is an application instance became unresponsive\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"TCP: out of memory \u2014 consider tuning tcp_mem - System Code Geeks - 2026\" \/>\n<meta property=\"og:description\" content=\"Interested to learn about AWS EC2 instances? Check our article explaining what to do is an application instance became unresponsive\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\" \/>\n<meta property=\"og:site_name\" content=\"System Code Geeks\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/systemcodegeeks\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/tier1app\" \/>\n<meta property=\"article:published_time\" content=\"2019-09-11T14:15:10+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"150\" \/>\n\t<meta property=\"og:image:height\" content=\"150\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Ram Lakshmanan\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@tier1app\" \/>\n<meta name=\"twitter:site\" content=\"@systemcodegeeks\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Ram Lakshmanan\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\"},\"author\":{\"name\":\"Ram Lakshmanan\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/#\/schema\/person\/1a018eb94d770751799b1be92acc80c9\"},\"headline\":\"TCP: out of memory \u2014 consider tuning tcp_mem\",\"datePublished\":\"2019-09-11T14:15:10+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\"},\"wordCount\":771,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg\",\"keywords\":[\"CPU\",\"TCP\"],\"articleSection\":[\"Linux\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\",\"url\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\",\"name\":\"TCP: out of memory \u2014 consider tuning tcp_mem - System Code Geeks - 2026\",\"isPartOf\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg\",\"datePublished\":\"2019-09-11T14:15:10+00:00\",\"description\":\"Interested to learn about AWS EC2 instances? Check our article explaining what to do is an application instance became unresponsive\",\"breadcrumb\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage\",\"url\":\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg\",\"contentUrl\":\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg\",\"width\":150,\"height\":150},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.systemcodegeeks.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Linux\",\"item\":\"https:\/\/www.systemcodegeeks.com\/category\/linux\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"TCP: out of memory \u2014 consider tuning tcp_mem\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/#website\",\"url\":\"https:\/\/www.systemcodegeeks.com\/\",\"name\":\"System Code Geeks\",\"description\":\"Operating System Developers Resource Center\",\"publisher\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.systemcodegeeks.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/#organization\",\"name\":\"Exelixis Media P.C.\",\"url\":\"https:\/\/www.systemcodegeeks.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png\",\"contentUrl\":\"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png\",\"width\":864,\"height\":246,\"caption\":\"Exelixis Media P.C.\"},\"image\":{\"@id\":\"https:\/\/www.systemcodegeeks.com\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/systemcodegeeks\",\"https:\/\/x.com\/systemcodegeeks\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/#\/schema\/person\/1a018eb94d770751799b1be92acc80c9\",\"name\":\"Ram Lakshmanan\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.systemcodegeeks.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/59f725950776f1f41edc0b0d176c4a0167683c210ddbf14647f1003bd6956739?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/59f725950776f1f41edc0b0d176c4a0167683c210ddbf14647f1003bd6956739?s=96&d=mm&r=g\",\"caption\":\"Ram Lakshmanan\"},\"description\":\"Ram Lakshmanan developed world's finest DevOps tools: GCeasy.io, fastThread.io, HeapHero.io. Every single day, millions &amp; millions of people in North America\u2014bank, travel, and commerce\u2014use the applications that Ram Lakshmanan has architected. Ram is an acclaimed speaker in major conferences on scalability, availability, and performance topics. Recently, he has founded a startup, which specializes in troubleshooting performance problems.\",\"sameAs\":[\"https:\/\/blog.heaphero.io\",\"https:\/\/www.facebook.com\/tier1app\",\"https:\/\/www.linkedin.com\/company\/gceasy\",\"https:\/\/x.com\/tier1app\"],\"url\":\"https:\/\/www.systemcodegeeks.com\/author\/ram-lakshmanan\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"TCP: out of memory \u2014 consider tuning tcp_mem - System Code Geeks - 2026","description":"Interested to learn about AWS EC2 instances? Check our article explaining what to do is an application instance became unresponsive","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:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/","og_locale":"en_US","og_type":"article","og_title":"TCP: out of memory \u2014 consider tuning tcp_mem - System Code Geeks - 2026","og_description":"Interested to learn about AWS EC2 instances? Check our article explaining what to do is an application instance became unresponsive","og_url":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/","og_site_name":"System Code Geeks","article_publisher":"https:\/\/www.facebook.com\/systemcodegeeks","article_author":"https:\/\/www.facebook.com\/tier1app","article_published_time":"2019-09-11T14:15:10+00:00","og_image":[{"width":150,"height":150,"url":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg","type":"image\/jpeg"}],"author":"Ram Lakshmanan","twitter_card":"summary_large_image","twitter_creator":"@tier1app","twitter_site":"@systemcodegeeks","twitter_misc":{"Written by":"Ram Lakshmanan","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#article","isPartOf":{"@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/"},"author":{"name":"Ram Lakshmanan","@id":"https:\/\/www.systemcodegeeks.com\/#\/schema\/person\/1a018eb94d770751799b1be92acc80c9"},"headline":"TCP: out of memory \u2014 consider tuning tcp_mem","datePublished":"2019-09-11T14:15:10+00:00","mainEntityOfPage":{"@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/"},"wordCount":771,"commentCount":0,"publisher":{"@id":"https:\/\/www.systemcodegeeks.com\/#organization"},"image":{"@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage"},"thumbnailUrl":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg","keywords":["CPU","TCP"],"articleSection":["Linux"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/","url":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/","name":"TCP: out of memory \u2014 consider tuning tcp_mem - System Code Geeks - 2026","isPartOf":{"@id":"https:\/\/www.systemcodegeeks.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage"},"image":{"@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage"},"thumbnailUrl":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg","datePublished":"2019-09-11T14:15:10+00:00","description":"Interested to learn about AWS EC2 instances? Check our article explaining what to do is an application instance became unresponsive","breadcrumb":{"@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#primaryimage","url":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg","contentUrl":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2016\/01\/linux-logo.jpg","width":150,"height":150},{"@type":"BreadcrumbList","@id":"https:\/\/www.systemcodegeeks.com\/linux\/tcp-out-of-memory-consider-tuning-tcp_mem\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.systemcodegeeks.com\/"},{"@type":"ListItem","position":2,"name":"Linux","item":"https:\/\/www.systemcodegeeks.com\/category\/linux\/"},{"@type":"ListItem","position":3,"name":"TCP: out of memory \u2014 consider tuning tcp_mem"}]},{"@type":"WebSite","@id":"https:\/\/www.systemcodegeeks.com\/#website","url":"https:\/\/www.systemcodegeeks.com\/","name":"System Code Geeks","description":"Operating System Developers Resource Center","publisher":{"@id":"https:\/\/www.systemcodegeeks.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.systemcodegeeks.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.systemcodegeeks.com\/#organization","name":"Exelixis Media P.C.","url":"https:\/\/www.systemcodegeeks.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.systemcodegeeks.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png","contentUrl":"https:\/\/www.systemcodegeeks.com\/wp-content\/uploads\/2022\/06\/exelixis-logo.png","width":864,"height":246,"caption":"Exelixis Media P.C."},"image":{"@id":"https:\/\/www.systemcodegeeks.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/systemcodegeeks","https:\/\/x.com\/systemcodegeeks"]},{"@type":"Person","@id":"https:\/\/www.systemcodegeeks.com\/#\/schema\/person\/1a018eb94d770751799b1be92acc80c9","name":"Ram Lakshmanan","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.systemcodegeeks.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/59f725950776f1f41edc0b0d176c4a0167683c210ddbf14647f1003bd6956739?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/59f725950776f1f41edc0b0d176c4a0167683c210ddbf14647f1003bd6956739?s=96&d=mm&r=g","caption":"Ram Lakshmanan"},"description":"Ram Lakshmanan developed world's finest DevOps tools: GCeasy.io, fastThread.io, HeapHero.io. Every single day, millions &amp; millions of people in North America\u2014bank, travel, and commerce\u2014use the applications that Ram Lakshmanan has architected. Ram is an acclaimed speaker in major conferences on scalability, availability, and performance topics. Recently, he has founded a startup, which specializes in troubleshooting performance problems.","sameAs":["https:\/\/blog.heaphero.io","https:\/\/www.facebook.com\/tier1app","https:\/\/www.linkedin.com\/company\/gceasy","https:\/\/x.com\/tier1app"],"url":"https:\/\/www.systemcodegeeks.com\/author\/ram-lakshmanan\/"}]}},"_links":{"self":[{"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/posts\/4239","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/users\/5445"}],"replies":[{"embeddable":true,"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/comments?post=4239"}],"version-history":[{"count":0,"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/posts\/4239\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/media\/192"}],"wp:attachment":[{"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/media?parent=4239"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/categories?post=4239"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.systemcodegeeks.com\/wp-json\/wp\/v2\/tags?post=4239"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}