Cascading Corefiles

Cascading Corefiles

Post by Andrew Giert » Sat, 12 Jul 1997 04:00:00

 fletcher> If I have interrelated programs running and one
 fletcher> program dumps core, and shortly thereafter, the
 fletcher> other programs dump core as a result, then I lose
 fletcher> the contents of the original core file because it is
 fletcher> overwritten by the succeeding core files.

 fletcher> I know how to solve this problem in SunOS by using
 fletcher> the system call "gcore" in conjunction with a signal
 fletcher> handler.  What I need to know is can this same problem
 fletcher> be solved on AIX and HPUX?

Catch SIGSEGV, SIGBUS, and other relevent signals, preferably
using SA_RESETHAND. In the signal handler, make a subdirectory
based on the process ID, chdir into it, and reraise the signal.

Alternatively, make your programs chdir to separate directories in
the first place.


comp.unix.programmer FAQ: see <URL:>


1. corefiles

How can i check what went wrong, which produced a corefile?

I have sendmail, it worked fine, i recompiled it and sind than it
creates corefiles, and on what went wrong.  I have no clear info on what
has changed in the meantime on my machine, but i gues that there is a
corrupted library somewhere.  I though you could use adb, but i don't
know how.

2. mgetty+sendfax & dip -i

3. NEED 'corefile' on Linux 1.3.3

4. ANYBODY have SB Live working with SMP?

5. Problem with "corefile truncation" on Solaris 8

6. EXMH available for Linux/X11 ?

7. gdb corefile debug problem: not in exe format

8. PPP timeout under RedHat 4.1

9. dbx, corefile problem

10. gdb-4.15, ELF, corefiles

11. gdb corefile debug problem: not in exe format

12. how to get suid corefiles?

13. reading large corefiles?