h1. Debug Asterisk Asterisk has several debug modes: *verbose* - various debug information is displayed, which related to step-by-step execution of call handling and various information of the call. *debug* - information for developers is displayed Messages for _verbose_ mode by default are directed to Asterisk console and to log file /var/log/asterisk/messages. Messages for _debug_ mode by default are directed to log file /var/log/asterisk/messages. For both modes you can set +log level+ (from 0 to 10). The higher is the level, the more information you get. For regular users usually _verbose_ mode is enough. To turn on logging perform next: 1. [[How to acquire root access|Acquire _root_ access]] 2. Enter Asterisk console:
# asterisk -r
3. Set mode and log level:
CLI> core set verbose 3
This will enable _verbose_ mode, level 3. On this level you'll see step-by-step call handler execution. To turn on _debug_ mode perform following:
CLI> core set debug 5
This will enable _verbose_ mode level 5. 4. Logging to file might quickly overflow disk space, thus after debugging is finished it's essential to turn off logging:
CLI> core set debug off
CLI> core set verbose off
[[Отладка Asterisk|Русский перевод]]