Simpler Navigation for Servers and Operating Systems
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
General
cancel
Showing results for 
Search instead for 
Did you mean: 

Few questions on GDB ( GNU DEBUGGER)

Masthan
Advisor

Few questions on GDB ( GNU DEBUGGER)


Hi All,

I am New to use gdb tool. I am facing couple of issues to use gdb tool. Can you please help by answering the following questions.

(1) How can I fetch my data structures from a core dump file? (like a specific variable value, a pointer value , or strcucture member value..etc).

(2) What is the use of "-s" option and how we can use this

(3) From a running process how I can fetch my data structures ?

(4)To analyze a core dump, do we need to the source files and executable file? If so, how to analyze a core dump using its sources.


(5) How to tell the gdb to look into a specific directory for source files or executables.

Thanks for your help in advance.

Regards
Masthan

2 REPLIES
avizen9
Esteemed Contributor

Re: Few questions on GDB ( GNU DEBUGGER)

Hello Masthan
i am not really good in gnu, but can suggest you below few url, thanks,

http://www.yolinux.com/TUTORIALS/GDB-Commands.html

http://arioch.unomaha.edu/~jclark/gdb_plus.html
dirk dierickx
Honored Contributor

Re: Few questions on GDB ( GNU DEBUGGER)

what you need to do is compile your programs with debug information. when you do that you can easily use gdb to do any of those things, in fact it's all transparent.

i recommend to use the gdb gui though, it makes life much easier. i always used ddd, but there is also insight (developed by redhat).

ddd: http://www.gnu.org/software/ddd/
insight: http://sources.redhat.com/insight/index.php