[ejabberd] ejabber crash

Tiaan tiaanh at gmail.com
Sat Nov 19 12:25:03 MSK 2005

> > I agree, it would be strange for ejabberd to restart the VM, but the wording
> > of the messages put some doubt in my mind.
> Just a guess: It seems that it might be much more something like the
> erlang "heart" behaviour. ejabberd might be the name of the registered
> service. A problem might cause the Erlang VM to crash (or at least not
> respond properly to heartbeat probes) and an heartbeat process might
> restart it. I think the heart behaviour (also available on *nix),
> might be enable by default on the Windows service.
> I hope this helps,

Yes, it helped a lot.

The ErlSrv "OnFail" paramater for the ejabberd service is set to
"restart", the default is "ignore", I guess the ejabberd installation
changed it to "restart". This certainly explain why the service was
restarted. Detail on ErlSrv can be found in

> Now, that does not solve the problem itself. Is there any more details
> in ejabberd logs ?

The ejabberd logs just have periods of inactivity when it restarted,
but no errors. From an extract of the crash dump below it seems like
it could not allocate memory from the heap.

Thu Nov 17 19:49:20 2005
Slogan: eheap_alloc: Cannot allocate 97953500 bytes of memory (of type "heap").
System version: Erlang (BEAM) emulator version 5.4.9 [threads:0]
Compiled: Tue Aug 30 01:23:58 2005
Atoms: 9081
total: 1266379392
processes: 1203005717
processes_used: 1202921909
system: 63373675
atom: 415325
atom_used: 395084
binary: 28513455
code: 3782916
ets: 15825060

I found the following post on a Java forumn, don't know if it's
coincidence, but in both cases the VMs could not allocate more than

In 1.3.0 win32 the maximum possible heap limit is about 1.2GB,
although the OS supports 2GB address space per process. This is caused
by the way the JDK DLLs are rebased, and a simple change will increase
the maximum possible heap limit to 1.6 or even 1.9GB.

Another option is to boot Windows with the /3GB switch, allowing 3GB
of user process space, but I'm not sure if the erlang VM will use the
additional available memeory.

I will post these questions in the erlang forumn.

More information about the ejabberd mailing list