Debug memory leak in distro FPBX


(Bukan) #1

Hello. Im use distro FPBX. How i can collect the dump memory leak?


(Matthew Fredrickson) #2

What makes you think that something is leaking memory?


(Bukan) #3

Every 5-7 days, my asterisk server write me error:

WARNING[2818][C-00003345] pbx.c: Failed to create new channel thread
WARNING[2818][C-00003345] chan_sip.c: Failed to start PBX :frowning:
ERROR[2811] tcptls.c: TCP/TLS unable to launch helper thread: Cannot allocate memory
ERROR[2755] tcptls.c: TCP/TLS unable to launch helper thread: Cannot allocate memory
WARNING[2804] pbx.c: Failed to create new channel thread
WARNING[2804] chan_iax2.c: Unable to start PBX on IAX2/iaxpc-8743


(Itzik) #4

Please post more information about your setup. (Resources, FreePBX/Asterisk version, anything custom etc etc etc. I also see that you are using ChanSIP with TLS?)

Then you can also post the output of:

free -m

Also, a screenshot of htop sorted by memory.


(Bukan) #5

custom module only chan_sccp

in moment error, free -m :
total used free shared buff/cache available
Mem: 5805 2280 1863 327 1661 2829
Swap: 3967 264 3703

but VIRT memory > 18 GB

and Committed_AS > CommitLimit
image

Every day VIRT memor grows on average 2-3 GB


(Daniel Friedman) #6

Hello @bknv,

It seems that your resources too low (especially the memory because it is using the SWAP).
Can you raise it to 8 CPUs and 16GB of memory?

Send us the results after it.

Thank you,

Daniel Friedman
Trixton LTD.


(Bukan) #7

Hello @danielf. I can, but i think this it will be superfluous. If i adding +4 CPU and 8GB RAM problem is will save, because after start service asterisk VIRT memory using 2-3 GB RAM and everyday increases every day + 2-3 GB RAM.

Is it possible to understand what exactly captured so much memory


#8

You have lots of copies of asterisk started, thus shoul never happen. Look in /var/log/messages for signs of asterisk crashing.


(Matthew Fredrickson) #9

Yeah those definitely look like symptoms of a memory leak. Does it still happen with chan_sccp disabled?


(Bukan) #10

Hello.
@mfredrickson disable chan_sccp for me very critical, because 80% my device work on this protocol. Are there any tools to debug leaks?
@dicko In /var/log/message doesn’t message about problem with asterisk.


(system) closed #11

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.