07-14-07 12:21 AM
Hello, I am debugging something and would like a process to suspend
temporarily. I wrote a script to send a SIGSTOP signal to that process
when another process is present. However, after receiving SIGSTOP, the
process I want to suspend keeps executing. I know that process get the
SIGSTOP from strace:
[pid 6850] 07:18:58.562518 --- SIGSTOP (Stopped (signal)) @ 0 (0) ---
[pid 6850] 07:18:58.562749 --- SIGSTOP (Stopped (signal)) @ 0 (0) ---
[pid 6850] 07:18:58.562970 wait4(-1, NULL, 0, NULL) = 6900
[pid 6850] 07:18:58.566868 open("/tmp/data-6850", O_RDONLY) = 3
[pid 6850] 07:18:58.567065 fstat(3, {st_mode=S_IFREG|0644,
st_size=5, ...}) = 0
[pid 6850] 07:18:58.567218 mmap(NULL, 4096, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2af684160000
[pid 6850] 07:18:58.567315 fstat(3, {st_mode=S_IFREG|0644,
st_size=5, ...}) = 0
[pid 6850] 07:18:58.567450 lseek(3, 0, SEEK_SET) = 0
[pid 6850] 07:18:58.569768 read(3, "6904\n", 5) = 5
[pid 6850] 07:18:58.570754 lseek(3, 5, SEEK_SET) = 5
[pid 6850] 07:18:58.570906 close(3) = 0
[pid 6850] 07:18:58.571067 munmap(0x2af684160000, 4096) = 0
Does anybody know how this could be possible? SIGSTOP should not be
ignored, caught, or blocked.
Thanks.
[ Post a follow-up to this message ]
|