core.6133: ELF 32-bit LSB core file Intel 80386, version 1 (SYSV),SVR4-style, from 'core_dump_test'
在Linux下可以用GDB来调试core文件。
gdb core_dump_test core.6133
GNU gdb Red Hat Linux(5.3post-0.20021129.18rh)
Copyright 2003 Free Software Foundation,Inc.
GDB is free software, covered by the GNU General Public License,and you are
welcome to change it and/or distribute copies of it under certainconditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type"show warranty" for details.
This GDB was configured as"i386-redhat-linux-gnu"...
Core was generated by `./core_dump_test'.
Program terminated with signal 11, Segmentationfault.
Reading symbols from/lib/tls/libc.so.6...done.
Loaded symbols for /lib/tls/libc.so.6
Reading symbols from/lib/ld-linux.so.2...done.
Loaded symbols for /lib/ld-linux.so.2
#0 0x080482fd in core_test () atcore_dump_test.c:7
7 str[1] = 'T';
(gdb) where
#0 0x080482fd in core_test () atcore_dump_test.c:7
#1 0x08048317 in main () atcore_dump_test.c:12
#2 0x42015574 in __libc_start_main () from/lib/tls/libc.so.6
在下列条件下不产生core文件:
( a )进程是设置-用户-ID,而且当前用户并非程序文件的所有者;
( b )进程是设置-组-ID,而且当前用户并非该程序文件的组所有者;
( c )用户没有写当前工作目录的许可权;
( d)文件太大。core文件的许可权(假定该文件在此之前并不存在)通常是用户读/写,组读和其他读。