Debugging GNOME DVB Daemon

Enabling debug output

To enable debug output of the daemon run

$ gnome-dvb-daemon --debug

To enable GStreamer's debug output run

$ GST_DEBUG=*:2,dvb*:3,mpeg*:5 gnome-dvb-daemon --gst-debug-no-color 2> debug.log

Getting a backtrace

$ gdb gnome-dvb-daemon

You should now see the gdb prompt. To start the daemon type

(gdb) run

When the crash appears type in

(gdb) thread apply all bt full

To redirect the output to a file (default is gdb.txt) run

(gdb) set logging on

Memory leaks

$ export GST_DIR=~/Projekte/gst/git/gstreamer
$ valgrind --tool=memcheck --leak-check=full --leak-resolution=high --trace-children=yes --num-callers=20 --suppressions=$GST_DIR/common/gst.supp -v gnome-dvb-daemon

Where GST_DIR points to the gstreamer git repository.

Creating image of pipeline

Add the following line somewhere in the code:

Gst.debug_bin_to_dot_file_with_ts ((Gst.Bin)this.pipeline, DebugGraphDetails.ALL, "pipeline");

Setup environment with

export GST_DEBUG_DUMP_DOT_DIR=`pwd`/debug

Create PNG image

dot -Tpng -opipeline.png

See also

Projects/DVBDaemon/Debugging (last edited 2013-11-22 02:28:51 by WilliamJonMcCann)