日期:2014-05-16 浏览次数:20916 次
#include <stdio.h>
int main()
{
while(1);
return 0;
}
$gcc -g test.c -o test
$./test &
[1] 31032
$kill -SIGBUS 31032
[1]+ 总线错误 (核心已转储) ./test
$ls | grep core
core
$
$sudo cat /var/log/apport.log
ERROR: apport (pid 30996) Wed Nov 27 14:00:22 2013: Unhandled exception:
Traceback (most recent call last):
File "/usr/share/apport/apport", line 258, in <module>
drop_privileges(pid, True)
File "/usr/share/apport/apport", line 54, in drop_privileges
raise ValueError('Invalid process ID: ' + str(e))
ValueError: Invalid process ID: [Errno 2] No such file or directory: '/proc/30994'
ERROR: apport (pid 30996) Wed Nov 27 14:00:22 2013: pid: 30996, uid: 0, gid: 0, euid: 0, egid: 0
ERROR: apport (pid 30996) Wed Nov 27 14:00:22 2013: environment: {}