If your application makes a call to an unknown module, your erl_crash.dump
file will contain a line like this one:
41DABB8:t4:A8:nonexistent_module,A7:unknown,N,N
where the "unknown" in the line indicates that the module nonexistent_module
can't be found. Searching your erl_crash.dump
file for the string "unknown" can help in these cases.
If you suspect a certain module makes a call to a function that doesn't exist, you can find it using the xref tool in an interactive erl shell. Make sure you compile the module with debug information (typically via erlc +debug_info
), then:
1> xref:m(my_module).
[{deprecated,[]},
{undefined,[{{my_module,init,1},{another_module,unknown,0}}]},
{unused,[]}]
Here, xref
shows us that the my_module:init/1
function makes a call to the another_module:unknown/0
function, but the unknown/0
function isn't defined in another_module
.
You can also use xref
to check entire applications; see the documentation for details