[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-smalltalk] SIGALRM and default handler
From: |
Holger Hans Peter Freyther |
Subject: |
[Help-smalltalk] SIGALRM and default handler |
Date: |
Mon, 15 Sep 2014 19:46:54 +0200 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
Dear Paolo,
I am running an image with gst-remote and it appears to be terminated
with SIGALRM due having a default handler. I thought it might have
been introduced by looking with GDB but it happens with strace (sure
both gdb and strace use ptrace).
The last seconds of the process:
clock_gettime(CLOCK_MONOTONIC, {43555416, 935715871}) = 0
rt_sigaction(SIGALRM, {0xb7699d50, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], 0},
{SIG_DFL, ~[QUIT ILL ABRT BUS KILL SEGV STOP RTMIN RT_1], 0}, 8) = 0
timer_settime(0x2, TIMER_ABSTIME, {it_interval={0, 0}, it_value={43555426,
935132484}}, NULL) = 0
clock_gettime(CLOCK_MONOTONIC, {43555416, 935873546}) = 0
clock_gettime(CLOCK_MONOTONIC, {43555416, 935909305}) = 0
clock_gettime(CLOCK_MONOTONIC, {43555416, 935934943}) = 0
rt_sigaction(SIGALRM, {0xb7699d50, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], 0},
{0xb7699d50, ~[QUIT ILL ABRT BUS KILL SEGV STOP RTMIN RT_1], 0}, 8) = 0
timer_settime(0x2, TIMER_ABSTIME, {it_interval={0, 0}, it_value={43555426,
935132484}}, NULL) = 0
rt_sigprocmask(SIG_BLOCK, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], [], 8) = 0
rt_sigsuspend([]) = ? ERESTARTNOHAND (To be restarted)
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigaction(SIGALRM, {SIG_DFL, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], 0},
{0xb7699d50, ~[QUIT ILL ABRT BUS KILL SEGV STOP RTMIN RT_1], 0}, 8) = 0
sigreturn() = ? (mask now ~[QUIT ILL ABRT BUS KILL
SEGV STOP RTMIN])
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
clock_gettime(CLOCK_MONOTONIC, {43555426, 935432004}) = 0
clock_gettime(CLOCK_MONOTONIC, {43555426, 935478859}) = 0
clock_gettime(CLOCK_MONOTONIC, {43555426, 935506023}) = 0
rt_sigaction(SIGALRM, {0xb7699d50, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], 0},
{SIG_DFL, ~[QUIT ILL ABRT BUS KILL SEGV STOP RTMIN RT_1], 0}, 8) = 0
timer_settime(0x2, TIMER_ABSTIME, {it_interval={0, 0}, it_value={43555426,
935873546}}, NULL) = 0
poll([{fd=7, events=POLLIN}], 1, 0) = 0 (Timeout)
poll([{fd=7, events=POLLIN}], 1, 0) = 0 (Timeout)
clock_gettime(CLOCK_MONOTONIC, {43555426, 935769073}) = 0
clock_gettime(CLOCK_MONOTONIC, {43555426, 935808586}) = 0
clock_gettime(CLOCK_MONOTONIC, {43555426, 935834467}) = 0
rt_sigaction(SIGALRM, {0xb7699d50, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], 0},
{0xb7699d50, ~[QUIT ILL ABRT BUS KILL SEGV STOP RTMIN RT_1], 0}, 8) = 0
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigaction(SIGALRM, {SIG_DFL, ~[QUIT ILL ABRT BUS SEGV RTMIN RT_1], 0},
{0xb7699d50, ~[QUIT ILL ABRT BUS KILL SEGV STOP RTMIN RT_1], 0}, 8) = 0
sigreturn() = ? (mask now [])
timer_settime(0x2, TIMER_ABSTIME, {it_interval={0, 0}, it_value={43555426,
935873546}}, NULL) = 0
--- SIGALRM (Alarm clock) @ 0 (0) ---
Process 4880 detached
So...
1.) We set rt_sigaction with SIGALRM and provide an address..
2.) We get the signal and set SIGALRM and something is setting
it back to the default handler and we receive a second SIGALRM.
So....
either we don't handle the "bottom-half" quick enough or the
kernel is sending us a SIGALRM too early.
In any case whoever sets rt_sigaction to default is probably
wrong ind oing that?
#0 *__GI___sigaction (sig=14, act=0xbfe20de4, oact=0xbfe20d58) at
../nptl/sigaction.c:37
#1 0xb768539a in _gst_set_signal_handler (signum=14, handlerFunc=0)
at sysdep/posix/signals.c:130
#2 0xb76b2daf in signal_handler (sig=14) at events.c:82
#3 <signal handler called>
#4 0xb76ff424 in __kernel_vsyscall ()
#5 0xb74f5b57 in do_sigsuspend (set=0xb760dff4)
at ../sysdeps/unix/sysv/linux/sigsuspend.c:63
So when handlerFunc=0 we seem to revert SIG_DEF for SIGALRM?
- [Help-smalltalk] SIGALRM and default handler,
Holger Hans Peter Freyther <=