[prev in list] [next in list] [prev in thread] [next in thread] 

List:       moblin-dev
Subject:    [Moblin Dev] RE: Debugging Network Manager Daemon -Need help
From:       todd.e.brandt () intel ! com (Brandt, Todd E)
Date:       2007-10-31 15:12:08
Message-ID: 9DFFE7E55170D941AA53E924DA2B6A63427645 () orsmsx412 ! amr ! corp ! intel ! com
[Download RAW message or body]

Raji, here's how I run gdb to get some useful info without having to
separate the exec from its normal execution environment. I simply
replace the text that spawns the program, wherever it is, with the
following:

 

gdb < cmdlist.gdb > log 2>&1

 

This enables the program to be run within gdb normally, without any
interacting programs knowing the difference (except for a little extra
latency), while I collect whatever information I want realtime and have
it displayed to stdout. The cmdlist.gdb file is where you setup how to
call the program and what information you want to grap. For example this
is how I debugged the time control panel applet in moblin-applets. The
control panel process is controlpanel and it pulls in the time.so
library when I double clicked the time icon in the cp window. 

 

Cmdlist.gdb contents:

 

file /usr/bin/controlpanel                        # this is where the
executable file is loaded, in this case the control panel

directory /platform/moblin-applets-0.4    # then you have to add in the
directories where the source is contained, this is for the time library
source

directory /platform/hildon-control-panel-1.9.5 # this directory is for
the control panel source

list hcp_app_idle_launch                        # then I have gdb list
out a function that is close to where the execute call is which loads up
the time library

break 200                                              # I then set a
break on that line so that execution will stop just prior to time.so
beling loaded

run                                                        # then I run
to that line, which is just prior to the call to load time.so

step                                                      # then I step
into the call, which loads time.so and all its synbols, so now I can
start debugging the time code

commands                                            # with the
commands-> continue -> end statement I tell gdb what to do if it ever
reaches the most recently set bp

continue                                                            # in
this case it means that if the break just execute it hit again, I just
want it to print the break and continue

end                                                       

break gst_tool_class_init                       # here I set another
brackpoint ona function of interest

commands                                            # then I set the
behavior to just print that gdb has hit this break, then to continue
executing

continue

end

break report_window_close_cb              # I continue this setup for
all the functions of interest, because I just want to follow the
function call flow

commands                                            # without
interfering with the execution of the code

continue

end

break scroll_to

commands

continue

end

break zoom_do

commands

continue

end

break load_map_background

commands

continue

end

break adjustment_changed_cb

commands

continue

end

break update_and_paint

commands

continue

end

break update_render_point

commands

continue

end

break repaint_point

commands

continue

end

list

continue                        # now I continue and let the program run
while printing out everything I want to see

 

 

The purpose of this run is to just instrument your target program with
debugging code that alerts you of what's going on without affecting 

The execution.

 

________________________________

From: Bommaraju, Rajyalakshmi 
Sent: Wednesday, October 31, 2007 2:43 PM
To: dev@moblin.org
Cc: Brandt, Todd E; asac@ubuntu.com
Subject: Debugging Network Manager Daemon -Need help

 

I am debugging Network Manager on the CrownBeach machine with SDIO WLAN
card on Ubuntu Gutsy. I saw that Network Manager daemon is crashing when
I try to connect to any wireless AP with or without security enabled
through nm-applet. Attached the log I captured during the crash. Looking
at the log, I am suspecting that WPA SUPPLICANT is having problem
connecting to global sockets and crashes the Network Manager Daemon.
But I am not sure 100% as I have no other information about the crash. I
used gdb and tried to gather back trace after the crash but that did not
work. Gdb says 'No symbols found' for 'bt' or 'bt full'.  I wanted to
know if there are any other logs that I can gather  to understand the
cause of the crash. How do I enable gdb to give out the 'backtrace'. 

 

Thanks,

Raji Bommaraju

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic