rust-gdb binary pid
gcore pid
bt
: prints all framesframe <num>
: switches to frameinfo locals
: prints variables in frame
info break
: list breakpointsdel 3
: delete breakpoint 3 or:clear filename:linenum
Inside GDB:
thread apply all bt
Given a core-dump save the backtraces to a file:
gdb binary coredump -ex "thread apply all bt" -ex "quit" > backtrace.log
Alternative with logging to file inside gdb:
(gdb) set logging on
(gdb) thread apply all bt