About asterisk log

Sometime, Maybe our asterisk crashed,but how to know why? I wish asterisk can log more information in file,who can help me how to get more information useful for crashed?