1CORE(5) 386BSD Programmer's Manual CORE(5) 2 3NNAAMMEE 4 ccoorree - memory image file format 5 6SSYYNNOOPPSSIISS 7 ##iinncclluuddee <<ssyyss//ppaarraamm..hh>> 8 9DDEESSCCRRIIPPTTIIOONN 10 A small number of signals which cause abnormal termination of a process 11 also cause a record of the process's in-core state to be written to disk 12 for later examination by one of the aviailable debuggers. (See 13 sigaction(2).) This memory image is written to a file named 14 pprrooggnnaammee..ccoorree in the working directory, where progname is replaced by the 15 name of the program; provided the terminated process had write permission 16 in the directory, the filesystem on which the working directory is on was 17 not mounted with the option _n_o_c_o_r_e (See mount(8)), and provided the 18 abnormality did not cause a system crash. (In this event, the decision 19 to save the core file is arbitrary, see savecore(8).) 20 21 The maximum size of a ccoorree file is limited by setrlimit(2). Files which 22 would be larger than the limit are not created. Also, the kernel tries 23 hard to not overwrite an existing file unless it is in standard coredump 24 format and was produced from the same program. 25 26 The ccoorree file consists of the _u. area, whose size (in pages) is defined 27 by the UPAGES manifest in the <_s_y_s/_p_a_r_a_m._h> file. The _u. area starts 28 with a _u_s_e_r structure as given in <_s_y_s/_u_s_e_r._h>. The remainder of the ccoorree 29 file consists of the data pages followed by the stack pages of the 30 process image. The amount of data space image in the ccoorree file is given 31 (in pages) by the variable _u__d_s_i_z_e in the _u. area. The amount of stack 32 image in the core file is given (in pages) by the variable _u__s_s_i_z_e in the 33 _u. area. The size of a ``page'' is given by the constant NBPG (also from 34 <_s_y_s/_p_a_r_a_m._h>). 35 36SSEEEE AALLSSOO 37 adb(1), dbx(1), gdb(1), kgdb(1), sigaction(2), setrlimit(2) 38 39HHIISSTTOORRYY 40 A ccoorree file format appeared in Version 6 AT&T UNIX. 41 424th Berkeley Distribution April 29, 1991 1 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67