← Volver al índice de módulos

debugger

This module provides an interactive config file debugger. It can print a trace of config script execution for a SIP message to log and set breakpoints on every script action, allowing step-by-step exe
📊 Monitorización y Logging Kamailio 6.1 30 parámetros 6 funciones

Descripción general

This module provides an interactive config file debugger. It can print a trace of config script execution for a SIP message to log and set breakpoints on every script action, allowing step-by-step execution of the routing and response scripts. Moreover, this module allows setting static and dynamic module specific debug settings. Debugging can be done from local or remote host via RPC interface (e.g., XMLRPC, kamcmd, siremis). The framework to set breakpoints on specific actions and config lines is not exported to RPC. Each action can be accompanied by a breakpoint or you can use dbg_breakpoint() function to set a breakpoint at certain line. Global breakpoints can be enabled/disabled at runtime. The script running trace can also be enabled/disabled at runtime. When the SIP router process is stopped at a breakpoint, you can investigate the values of any pseudo-variables. Note that some of pseudo-variables may produce memory leaks; a fix is planned in the future (here fall pseudo-variables with dynamic name such as htable, sqlops). References to SIP message, avps, headers, script and shared variables are safe.

Documentación oficial: https://www.kamailio.org/docs/modules/stable/modules/debugger.html
Código fuente: https://github.com/kamailio/kamailio/tree/master/src/modules/debugger

Parámetros de configuración

ParámetroTipoDescripción
cfgtrace int 3.2. cfgtrace_format (int) 3.3. breakpoint (int) 3.4. log_level (int) 3.5. log_level_name (str) 3.6. log_facility (str) 3.7. log_prefix (str) 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_has
cfgtrace_format int 3.3. breakpoint (int) 3.4. log_level (int) 3.5. log_level_name (str) 3.6. log_facility (str) 3.7. log_prefix (str) 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_leve
breakpoint int 3.4. log_level (int) 3.5. log_level_name (str) 3.6. log_facility (str) 3.7. log_prefix (str) 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod
log_level int 3.5. log_level_name (str) 3.6. log_facility (str) 3.7. log_prefix (str) 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mo
log_level_name str 3.6. log_facility (str) 3.7. log_prefix (str) 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14
log_facility str 3.7. log_prefix (str) 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.1
log_prefix str 3.8. step_usleep (int) 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.15. log_assign (int) 3.
step_usleep int 3.9. step_loops (int) 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3
step_loops int 3.10. mod_hash_size (int) 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int)
mod_hash_size int 3.11. mod_level_mode (int) 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int) 3.18. cfgtest (int)
mod_level_mode int 3.12. mod_level (str) 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int) 3.18. cfgtest (int)
mod_level str 3.13. mod_facility_mode (int) 3.14. mod_facility (str) 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int) 3.18. cfgtest (int)
mod_facility_mode int 3.14. mod_facility (str) 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int) 3.18. cfgtest (int)
mod_facility str 3.15. log_assign (int) 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int) 3.18. cfgtest (int)
log_assign int 3.16. cfgpkgcheck (int) 3.17. reset_msgid (int) 3.18. cfgtest (int)
cfgpkgcheck int 3.17. reset_msgid (int) 3.18. cfgtest (int)
reset_msgid int 3.18. cfgtest (int)
cfgtest int 3.1. cfgtrace (int)
cfgtrace int Control whether the config script trace is enabled or disabled at startup. You can change the value at runtime without restart, globally or per process.
cfgtrace_format int Control what is printer in the cfgtrace log message. If it is set to 1, then the configuration file path is not printed, making the log messages shorter when not including other configuration files in
breakpoint int Control whether every line (global) breakpoint is enabled or disabled at startup.
log_level int What log level is to be used to print module-specific messages.
log_level_name str What log level name is to be used to print cfg trace messages.
log_facility str Which log facility is to be used to print module-specific messages. By using this setting, you can configure syslog to send debug messages to a separate log channel, like a specific kamailio-debug log
log_prefix str String to print before any module-specific messages.
step_usleep int Microseconds to sleep before checking for new commands when waiting at a breakpoint.
step_loops int How many sleeps of 'step_usleep' the RPC process performs when waiting for a reply from a worker process before responding to RPC. This avoids blocking RPC process forever in case the worker process '
mod_hash_size int Used to compute power of two as size of internal hash table to store levels per module (e.g., if it is set to 4, internal hash table has 16 slots). One must set its value grater than 0 such that memor
mod_level_mode int Enable or disable per module log level (0 - disabled, 1 - enabled). This parameter is tunable via the Kamailio config framework. To use per module log level you also have to set mod_hash_size.
mod_level str Specify module log level - the value must be in the format: modulename=level. The parameter can be set many times. For core log level, use module name 'core'. You also must enable mod_level_mode and m

Funciones exportadas

dbg_breakpoint(mode)

4.2. dbg_pv_dump([mask] [, level]) 4.3. dbg_sip_msg([log_level], [facility])

dbg_pv_dump([mask] [, level])

4.3. dbg_sip_msg([log_level], [facility])

dbg_sip_msg([log_level], [facility])

4.1. dbg_breakpoint(mode)

dbg_breakpoint(mode)

Anchor a breakpoint at the current line of the config (the one on which this function is called). The 'mode' specifies whether the breakpoint is enabled (1) or disabled (0) at startup.

dbg_pv_dump([mask] [, level])

Prints the content of pv_cache on json format. Defaults are mask=31 and level = "L_DBG"

dbg_sip_msg([log_level], [facility])

Prints how the sip message would look like if it would be sent out at that point in the config(i.e. if the current lump lists would have been applied at that point in the config). It also prints a diff list for both header and body of sip msg which c

Autores y contribuidores

Daniel-Constantin MierlaDaniel-Constantin Mierla <miconda@gmail.com>

Copyright © 2010 Daniel-Constantin Mierla (asipto.com)

Módulos relacionados

dlgs rtjson sipcapture siptrace statistics xlog