[erlang-questions] When does lager logs into crash.log?

Anders Nygren anders.nygren@REDACTED
Sat Jan 23 00:04:51 CET 2016


I don't know about the lager part, but, if I remember right, to get the
crash reports SASL needs to be started

On Fri, Jan 22, 2016 at 3:11 PM, Martin Koroudjiev <mrtndimitrov@REDACTED>
wrote:

> Hello,
>
> from what I read about the error_logger "Error, warning and info events
> are sent to the error logger from the Erlang runtime system and the
> different Erlang/OTP applications." So, I guess, errors in non-supervised
> code are also sent to the error_logger. But not to lager's crash file.
> Actually this badmatch error is not reported anywhere. How can I make lager
> report it?
>
> Regards,
> Martin
>
>
> On 1/22/2016 7:55 PM, Nathaniel Waisbrot wrote:
>
> dummy = application:get_env(myapp, test).
>
> This results in badmatch. But there is no entry in crash.log. I had
> configured another log file warning.log that gets populated with a
> one-liner but I would like to see the detailed report in crash.log.
>
>
>
> The crash.log comes from things that use the error_logger (
> http://erlang.org/doc/man/error_logger.html). Typically, this is OTP
> applications crashing.
>
> Try putting that badmatch inside of a gen_server's handle_cast/3 method
> and you should see lager's handling (and if you disable crash logging in
> lager you can see what the default error_logger does with it).
>
>
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20160122/59d1176b/attachment.htm>


More information about the erlang-questions mailing list