一直有应用程序被杀死的问题。这是运行 RHEL5 服务器。我们对进程运行了 strace,在跟踪文件的末尾,我得到了一堆被 SIGKILL +++消息杀死的 +++。SIGKILL 无法被捕获,所以我试图找到一种方法来追踪进程被杀死的原因。
我尝试使用 Red Hat 的一些建议,例如
auditctl -a exit,always -S kill
Run Code Online (Sandbox Code Playgroud)
这似乎不起作用。我在audit.log 中没有看到任何kill 条目。
Red Hat 的另一个建议是使用 systemtap。我通过 yum 安装它并尝试使用提供的 sigmon.stp 脚本运行 stap。sigmon.stp 在这个页面上:Sigmon.stp 我使用了评论部分提供的命令,这里是输出:
# stap sigmon.stp -x 12647 SIGKILL -v
Pass 1: parsed user script and 85 library script(s) using 146868virt/23716res/3024shr/21404data kb, in 110usr/10sys/116real ms.
semantic error: while resolving probe point: identifier 'kernel' at /usr/share/systemtap/tapset/signal.stp:60:37
source: probe __signal.send.send_sigqueue = kernel.function("send_sigqueue")
^
semantic error: missing x86_64 kernel/module debuginfo …Run Code Online (Sandbox Code Playgroud)