numtcpsock + erlang + ejabberd = BUGs

Hello, everybody
I found strange BUG

I have installed ejabberd on vps with openvz virtualization. By default value "numtcpsock" on vps is limited by 1000 connection
numtcpsock - it's maximum number of TCP sockets, limits the number of TCP connections

For me numtcpsock=1000 - it's not enough, and after I've asked vps provider to increase value "numtcpsock" to 2000, my ejabberd crashed after start and stop working

after increasing value numtcpsock=2000 from 1000, I start my ejabberd, it's working 3-5 minutes and than there is memory leak, memory rises quickly to 2gb (normal is 300-400 mb) and process "beam" crashes after it increasing to memory limit

ejabberd 2.1.13, elang - was 14b04, but I have updated to R16B02 (it's doesn't help me to avoid this bug)

in erlang.log I receive smth like that

=CRASH REPORT====
  crasher:
    initial call: gen:init_it/6
    pid: <0.529.0>
    registered_name: []
    exception exit: {process_limit,{max_queue,21}}
      in function  p1_fsm:terminate/7
      in call from p1_fsm:loop/10
    ancestors: [ejabberd_s2s_out_sup,ejabberd_sup,<0.37.0>]
    messages: []
    links: [<0.258.0>]
    dictionary: [{'$internal_queue_len',0},{random_seed,{1383,21131,18816}}]
    trap_exit: true
    status: running
    heap_size: 4181
    stack_size: 24
    reductions: 8777
  neighbours:

In /var/log/ejabberd/ I get crash file - erl_crash_20131103-211835.dump
with log

=erl_crash_dump:0.1
Sun Nov  3 21:18:36 2013
Slogan: Kernel pid terminated (application_controller) ({application_start_failure,kernel,{shutdown,{kernel,start,[normal,[]]}}})
System version: Erlang R14B04 (erts-5.8.5) [source] [64-bit] [smp:24:24] [rq:24] [async-threads:0] [kernel-poll:false]
Compiled: Sat Mar  2 06:38:11 2013
Taints:
Atoms: 4609
=memory
total: 20730288
processes: 550936
processes_used: 536256
system: 20179352
atom: 318953
atom_used: 298863
binary: 77216
code: 2189517
ets: 56616
=hash_table:atom_tab
size: 3203
used: 2457
objs: 4609
depth: 8
=index_table:atom_tab
size: 5120
limit: 1048576
entries: 4609

After I reboot vps or restart ejabberd, it's the same situationg - it's working 3-5 mins and that memory rises quickly in 4-5 times and process crash

After I asked my vps provider to decrease the "numtcpsock" to it's original value 1000, everything is working good

Help me please, what going on?
Why "numtcpsock" causes such situation? And how can I increase it's value?
Why erlang and ejabberd crashs?
Why there is such strange memory leak?
How "numtcpsock" is connected with erlang or ejabberd?

Also that I have changed in

Also that I have changed in ejabberd.cfg some value

For example, max_fsm_queue, I changed it to 10 and that to 3000 - it have no affect

Help, please Somebody knows,

Help, please

Somebody knows, why increasing of "numtcpsock" causes memory leak? and crash of service after that?

Guy, anybody knows, what

Guy, anybody knows, what attitude has "numtcpsock" to erlang or ejabberd? Why after increasing erlang and ejabberd crashes?

Syndicate content