2

I'm developping an app on ARM Linux platform (kernel 2.6.18 Montavista 5). When I send SIGKILL to the process (kill -9) the application keeps running. I am really puzzled by this situation as based on my (limited) understanding of Linux, this should just not be possible.

I noticed that this behavior depends on what the application is doing. I have a processing loop in this application for which I switch the terminal to raw mode. When I issue SIGKILL and the application is idle, the application gets terminated instantly (as expected). When I am in the processing loop, nothing happens. In other words, the process keeps producing data and executing system calls as shown by strace.

I would appreciate any hint as to what might be happening here.

user1766169
  • 1,932
  • 3
  • 22
  • 44
  • Could you provide any examples of the kill command output? Or is it possible to attach a debugger after you send the SIGKILL command? – foips Jan 09 '15 at 12:21
  • The kill -9 command returns silently. I can't attach a debugger easily but I ran the app through strace and it shows nothing. – Stéphane Mutz Jan 09 '15 at 13:22
  • Did You tried to wait a bit after kill? I would suspect it is because of slow terminal (it takes some time to finish writing data). May be related to "uninterruptable sleep" (some I/O operations can't be interrupted). – kestasx Jan 09 '15 at 20:09
  • The process keeps running and producing new data. It is not stuck in a syscall as strace continues to show a regular flow of syscalls. – Stéphane Mutz Jan 12 '15 at 10:21
  • this helped me (for python): http://stackoverflow.com/questions/4789837/how-to-terminate-a-python-subprocess-launched-with-shell-true – Ayrat Jun 11 '16 at 23:01

0 Answers0