Are you using CGo or libraries that use CGo? If so, you probably have an 
off-heap, i.e malloc() leak  

> On Feb 11, 2021, at 11:11 AM, Tom Mitchell <mi...@niftyegg.com> wrote:
> 
> 
> 
>> On Thu, Feb 11, 2021 at 3:40 AM Uli Kunitz <uli.kun...@gmail.com> wrote:
>> You are writing: The device crashes with out of memory. What does crash? The 
>> Go program, another program or the kernel? Can you share the error message? 
>> Can you share the log file for one day of GODEBUG=gctrace=1?
>> 
>> In bash do:
>> 
>> $ export GODEBUG=gctrace=1
>> $ <your-program-that-calls-the-Go-program> 2>error.log
>> 
>>> On Thursday, February 11, 2021 at 9:01:52 AM UTC+1 Miles Hex wrote:
>>> To be honest, i'm not totally sure, what is see is that memory keep raising 
>>> until the device crash for out of memory, but what does it mean if 
>>> reachable object remain constant, but the " Heap objects" keep raising?
> 
> Objects plural?
> What is the size of each heap object.  With garbage collection it can help to 
> have as few sizes as possible. Pad objects so when collected the free leaves 
> a useful size space in the heap.   Linux can allow the VM system to over 
> allocate resources and only discover when written and the page fault has no 
> backing store.  Add swap to file and or tune the VM system.   Limits -- set 
> limits low enough for the program so it cannot dominate system physical 
> resources. 
> Add signal handler code to dump a summary of all your live objects.  
> Recursion? Socket(state)? Events arrive faster than event handling?  
> Locks/Mutex: is housekeeping getting CPU time [phone booth rule, give 
> priority to leaving]?  
> 
> 
> -- 
>           T o m    M i t c h e l l ( o n   N i f t y E g g )
> -- 
> You received this message because you are subscribed to the Google Groups 
> "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to golang-nuts+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/golang-nuts/CAAMy4UQWV1Gt9UZBpjpAx01mhL5HEr8NCtGX1rnr1Hevui1Eiw%40mail.gmail.com.

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/EFB63B8F-89F7-4D62-A476-6381F446F65B%40ix.netcom.com.

Reply via email to