xpra icon
Bug tracker and wiki

Changes between Version 30 and Version 31 of Debugging


Ignore:
Timestamp:
12/12/13 08:35:10 (6 years ago)
Author:
Antoine Martin
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Debugging

    v30 v31  
    109109== GDB ==
    110110When dealing with crashes ("core dumped"), the best way to debug is to fire gdb.
    111 === Getting a Backtrace ===
     111=== Attaching to an existing xpra process ==
     112Find the pid of the xpra process:
    112113{{{
    113 xpra start ...
    114 # or xpra attach ...
    115114ps -ef | grep xpra
     115}}}
     116Then:
     117{{{
    116118gdb python $PID_OF_XPRA_PROCESS_TO_DEBUG
    117119# wait for it to load all the debug symbols
    118120(gdb) continue
    119121}}}
     122
     123=== Starting xpra in gdb ===
     124{{{
     125gdb python $PID_OF_XPRA_PROCESS_TO_DEBUG
     126run /usr/bin/xpra start ...
     127}}}
     128
     129=== Getting the backtrace ===
    120130Then once you get a crash, gdb should show you its prompt again and you can extract the python stacktrace with {{{py-bt}}} and the full stacktrace with {{{bt}}}. Having both is useful.
    121131Note: installing the required "debug" symbol packages for your distribution is out of scope, please refer to your vendor's package manager for details (ie: [http://wiki.debian.org/HowToGetABacktrace debian] and [http://yum.baseurl.org/wiki/YumUtils/DebugInfoInstall yum debuginfo-install]).