Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
installation_guide:debug:start [2024/02/19 16:09] – [Monitor the file descriptors] borjainstallation_guide:debug:start [2025/11/21 23:51] (current) – [View the traces flow] borja
Line 27: Line 27:
 <code> <code>
 root# tail -f /var/log/voximal/debug.log | ccze -A root# tail -f /var/log/voximal/debug.log | ccze -A
 +</code>
 +
 +With remove/reset log content :
 +<code>
 +root# > /var/log/voximal/debug.log ; tail -f /var/log/voximal/debug.log
 </code> </code>
  
Line 346: Line 351:
 </code> </code>
  
-==== Coredump generators ====+==== Generate a CallStacks or Coredumps ====
  
 Generate the threads stacks or a coredump file for the process (voximald) : Generate the threads stacks or a coredump file for the process (voximald) :
  
 <code> <code>
-gdb -ex "thread apply all bt" --batch /usr/sbin/voximald $(pidof voximald) > /var/log/voximal/backtrace-voximald$(date +%s).txt +gdb -ex "thread apply all bt" --batch /usr/sbin/asterisk $(pidof asterisk) > /var/log/voximal/backtrace-asterisk-$(date +%s).txt 
-gdb /usr/sbin/voximald $(pidof voximald) -ex "gcore /tmp/toto.core" --batch+ 
 +gdb -ex "thread apply all bt" --batch /usr/sbin/voximald $(pidof voximald) > /var/log/voximal/backtrace-voximald-$(date +%s).txt 
 + 
 +gdb /usr/sbin/asterisk$(pidof asterisk) -ex "gcore /tmp/asterisk-$(date +%s).core" --batch 
 + 
 +gdb /usr/sbin/voximald $(pidof voximald) -ex "gcore /tmp/voximald-$(date +%s).core" --batch 
 +</code> 
 + 
 +==== Execute the Asterisk with GDB (debugger) ==== 
 + 
 +Launch the Asterisk process with the debugger (gdb) : 
 + 
 +<code> 
 +gdb -ex=r --args asterisk -cvvvvvv -U asterisk -G asterisk 
 +</code> 
 + 
 +==== Attach the GDB (debugger) to the Asterisk ==== 
 + 
 +Launch the debugger process and attach to the running Asterisk : 
 + 
 +<code> 
 +gdb /usr/sbin/asterisk $(pidof asterisk) -iex "set pagination off" -ex cont
 </code> </code>
  
  • installation_guide/debug/start.1708358999.txt.gz
  • Last modified: 2024/02/19 16:09
  • by borja