{"id":2183,"date":"2015-03-30T14:50:53","date_gmt":"2015-03-30T13:50:53","guid":{"rendered":"http:\/\/mccltd.net\/blog\/?p=2183"},"modified":"2015-03-30T14:50:53","modified_gmt":"2015-03-30T13:50:53","slug":"understanding-f5-big-ip-memory-usage","status":"publish","type":"post","link":"http:\/\/darenmatthews.com\/blog\/?p=2183","title":{"rendered":"Understanding F5 BIG-IP Memory Usage"},"content":{"rendered":"<p>Any non-tmsh command you use in the HMS bash shell (like free) will generally only relate to the HMS. This is why there is an apparent discrepancy between the tmsh &#8220;show system memory&#8221; command and the Linux &#8220;free&#8221; command:<!--more--><\/p>\n<blockquote><p>[root@F5-BIG-IP:Active:Changes Pending] config # tmsh show sys memory | head<\/p>\n<p>Sys::System Memory Information<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\nMemory Used(bytes)\u00a0 Current\u00a0 Average\u00a0 Max(since 03\/30\/15 10:17:01)<br \/>\n&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\nTotal Phys Memory\u00a0\u00a0\u00a0\u00a0\u00a0 7.8G\u00a0\u00a0\u00a0\u00a0 7.8G\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 7.8G<br \/>\nOS Used Memory\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 7.6G\u00a0\u00a0\u00a0\u00a0 7.6G\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 7.6G<br \/>\nTMM Alloc Memory\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 2.8G\u00a0\u00a0\u00a0\u00a0 2.8G\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 2.8G<br \/>\nTMM Used Memory\u00a0\u00a0\u00a0\u00a0\u00a0 650.1M\u00a0\u00a0 649.8M\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 650.1M<br \/>\nOS Used Swap\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 0<\/p><\/blockquote>\n<p>The TMM shows low usage but the Linux OS shows only 160MB free out of 7.8GB:<\/p>\n<blockquote><p>[root@F5-BIG-IP:Active:Changes Pending] config # free -m<br \/>\ntotal\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 used\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 free\u00a0\u00a0\u00a0\u00a0 shared\u00a0\u00a0\u00a0 buffers\u00a0\u00a0\u00a0\u00a0 cached<br \/>\nMem:\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 7996\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 7836\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 160\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 565\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 1373<br \/>\n-\/+ buffers\/cache:\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 5897\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 2098<br \/>\nSwap:\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 1023\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 1023<br \/>\n[root@F5-BIG-IP:Active:Changes Pending] config #<\/p><\/blockquote>\n<p>Top is one exception and will actually give you valid figures for CPU and memory (for the TMM processes), this is the only non-tmsh command you should rely upon. To avoid confusion it&#8217;s best to simply rely on tmsh commands:<\/p>\n<blockquote><p>top &#8211; 13:21:24 up 484 days,\u00a0 2:38,\u00a0 1 user,\u00a0 load average: 0.00, 0.03, 0.00<br \/>\nTasks: 295 total,\u00a0\u00a0 1 running, 294 sleeping,\u00a0\u00a0 0 stopped,\u00a0\u00a0 0 zombie<br \/>\nCpu(s):\u00a0 9.3%us,\u00a0 3.0%sy,\u00a0 0.7%ni, 87.1%id,\u00a0 0.0%wa,\u00a0 0.0%hi,\u00a0 0.0%si,\u00a0 0.0%st<br \/>\nMem:\u00a0\u00a0 8188268k total,\u00a0 8025028k used,\u00a0\u00a0 163240k free,\u00a0\u00a0 578620k buffers<br \/>\nSwap:\u00a0 1048568k total,\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 0k used,\u00a0 1048568k free,\u00a0 1406236k cached<\/p>\n<p>PID USER\u00a0\u00a0\u00a0\u00a0\u00a0 PR\u00a0 NI\u00a0 VIRT\u00a0 RES\u00a0 SHR S %CPU %MEM\u00a0\u00a0\u00a0 TIME+\u00a0 COMMAND<br \/>\n30872 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0 958m\u00a0 64m\u00a0 33m S 10.6\u00a0 0.8\u00a0 66033:18 tmm<br \/>\n30874 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0 1019m 125m\u00a0 94m S 10.2\u00a0 1.6\u00a0 65595:50 tmm<br \/>\n30871 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0 958m\u00a0 64m\u00a0 33m S\u00a0 9.9\u00a0 0.8\u00a0 66134:06 tmm<br \/>\n30873 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0 1019m 125m\u00a0 94m S\u00a0 9.9\u00a0 1.6\u00a0 71945:39 tmm<br \/>\n7017 root\u00a0\u00a0\u00a0\u00a0\u00a0 25\u00a0\u00a0 5 14752 5640 2240 S\u00a0 3.3\u00a0 0.1\u00a0 22308:35 merged<br \/>\n6133 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0 26008\u00a0 15m 2856 S\u00a0 1.7\u00a0 0.2\u00a0\u00a0 3341:04 statsd<br \/>\n7023 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0 27748\u00a0 14m 7060 S\u00a0 1.7\u00a0 0.2\u00a0 11418:43 pfmand<br \/>\n1241 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 2528 1224\u00a0 832 R\u00a0 0.7\u00a0 0.0\u00a0\u00a0 0:00.07 top<br \/>\n6670 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 113m\u00a0 65m\u00a0 11m S\u00a0 0.7\u00a0 0.8\u00a0\u00a0 4711:47 mcpd<br \/>\n5328 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 3204\u00a0 976\u00a0 824 S\u00a0 0.3\u00a0 0.0\u00a0\u00a0 1725:57 lopd<br \/>\n6024 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 1932\u00a0 808\u00a0 680 S\u00a0 0.3\u00a0 0.0\u00a0\u00a0 2175:09 LCDd<br \/>\n6388 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0 26656\u00a0 25m\u00a0 17m S\u00a0 0.3\u00a0 0.3 381:20.44 sod<br \/>\n6407 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 5784 2368 1148 S\u00a0 0.3\u00a0 0.0\u00a0\u00a0 3879:41 ntlmconnpool<br \/>\n7039 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 172m\u00a0 52m 4788 S\u00a0 0.3\u00a0 0.7 413:50.77 java<br \/>\n28625 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0 99.7m\u00a0 18m 8948 S\u00a0 0.3\u00a0 0.2\u00a0\u00a0 2040:50 apmd<br \/>\n1 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0 2160\u00a0 660\u00a0 564 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:46.12 init<br \/>\n2 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:03.85 kthreadd<br \/>\n3 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:02.32 migration\/0<br \/>\n4 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.03 ksoftirqd\/0<br \/>\n5 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 migration\/0<br \/>\n6 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 watchdog\/0<br \/>\n7 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:10.20 migration\/1<br \/>\n8 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 migration\/1<br \/>\n9 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.08 ksoftirqd\/1<br \/>\n10 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.08 watchdog\/1<br \/>\n11 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:04.01 migration\/2<br \/>\n12 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 migration\/2<br \/>\n13 root\u00a0\u00a0\u00a0\u00a0\u00a0 20\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 ksoftirqd\/2<br \/>\n14 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 watchdog\/2<br \/>\n15 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 1:26.87 migration\/3<br \/>\n16 root\u00a0\u00a0\u00a0\u00a0\u00a0 RT\u00a0\u00a0 0\u00a0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0\u00a0\u00a0\u00a0 0 S\u00a0 0.0\u00a0 0.0\u00a0\u00a0 0:00.00 migration\/3<\/p><\/blockquote>\n","protected":false},"excerpt":{"rendered":"<p>Any non-tmsh command you use in the HMS bash shell (like free) will generally only relate to the HMS. This is why there is an apparent discrepancy between the tmsh &#8220;show system memory&#8221; command and the Linux &#8220;free&#8221; command:<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[84],"tags":[73],"_links":{"self":[{"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/2183"}],"collection":[{"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2183"}],"version-history":[{"count":1,"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/2183\/revisions"}],"predecessor-version":[{"id":2184,"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/2183\/revisions\/2184"}],"wp:attachment":[{"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2183"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2183"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/darenmatthews.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2183"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}