<div dir="ltr"><span style="font-size:12.8px">Hello list,</span><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">I run one Erlang application on Debian server and today I find the beam process consumes around 35G memory by `top` command.</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px"><div>```</div><div>KiB Mem:  99194912 total, 61682656 used, 37512252 free,   397380 buffers</div><div>KiB Swap:        0 total,        0 used,        0 free. 18684864 cached Mem</div><div><br></div><div>  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND</div><div>11858 usr1   20   0 36.850g 0.032t   6220 S  73.5 34.4   8038:49 beam.smp</div><div>```</div><div><br></div><div>I connect to the Erlang application using remote shell and find the mem-leaked supervisor tree and run gc on the whole tree. Code looks like blow:</div><div><br></div><div>```</div><div>lists:foreach(fun(E) -> PId = element(2, E), erlang:garbage_collect(PId) end, supervisor:which_children(<wbr>some_thing_sup)).<br></div><div>```</div><div><br></div><div>and erlang:memory() decreases from 32G to 23G.</div><div>```</div><div><div>[{total,22982011544},</div><div> {processes,12884182336},</div><div> {processes_used,12884170336},</div><div> {system,10097829208},</div><div> {atom,13828705},</div><div> {atom_used,13796692},</div><div> {binary,170530288},</div><div> {code,16450626},</div><div> {ets,9637717576}]</div></div><div>```</div><div><br></div><div>However, when I input `top` command, the beam process still takes 35G memory. What can I do to release the 9G memory? Thanks</div><div><br></div><div>BR</div><div>-Jack</div></div></div>