LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   what is core dump and how to do it (https://www.linuxquestions.org/questions/programming-9/what-is-core-dump-and-how-to-do-it-497789/)

dayalan_cse 11-02-2006 02:26 AM

what is core dump and how to do it
 
hello,

how can i do core dump for c and c++ programs to debug using gdb. pls help me how can i do core dump?

Thanks & Regards
dayalan

jtshaw 11-02-2006 08:00 AM

A core file is a binary file with the state of the world (so to speak) when a program dies. You can force a program to die and generate a core with kill -6 <PID>. You need to make sure your ulimit is setup to allow you to have core files.

You can use gdb to debug a program via a core by by typing "gdb <programexe> <corefile>".

jlliagre 11-02-2006 04:06 PM

You can also generate a core file from a living application without killing it with the gcore command.
Gcore is only recently available under Gnu/Linux.

dayalan_cse 11-03-2006 01:59 AM

thanks
 
Quote:

Originally Posted by jlliagre
You can also generate a core file from a living application without killing it with the gcore command.
Gcore is only recently available under Gnu/Linux.


hi thank you to every one who responded to me. i am new for the linux your information has helped much.thank you once again.


Thanks & Regards
dayalan


All times are GMT -5. The time now is 06:47 PM.