如何分析堆芯转储



应用程序[rtcurrent]崩溃后,它生成了250MB的core文件。

Caught Segmentation fault, dumping stack:B] [Port: 58940][U 0/0] [D 0/10] [H 1/32] [S 72/75/768] [F 0/128]
Stack dump not enabled.
Aborted (core dumped)

我需要的是分析和查看堆栈跟踪,以了解rtcurrent为什么经常崩溃。

gdb应该能够分析核心:

gdb /path/to/binary/rtorrent /path/to/coredump/rtorrent.core

键入where以查看堆栈跟踪。

查看更多:使用调试符号编译rtcurrent,运行,等待崩溃,并使用gdb分析转储(在这种情况下,您可以看到崩溃发生的确切位置)。

UPD请注意,据我所知,rturrent是在libtorrent之上构建的,因此,您必须使用调试符号重建库和应用程序才能获得完整信息。

最新更新