Is it possible to generate a core dump without killing the process? If so, what is the command/signal to do so?
Thanks, Jim
Is it possible to generate a core dump without killing the process? If so, what is the command/signal to do so?
Thanks, Jim
See the 'gcore' command, part of GDB.
I had the best success with attaching gdb in batch mode to the running program, get a backtrace and then detach.
gdb --batch --quiet -ex "set pagination off" -ex "thread apply all bt"
-ex "detach" -ex "quit" pid pid_of_process
A method to generate a coredump directly from program without gdb
is described here:
https://unix.stackexchange.com/questions/11185/dump-process-core-without-killing-the-process
It make sense only if you are developing. Principle is to fork program and to raise SIGABRT
from child.
© 2022 - 2024 — McMap. All rights reserved.