[LEDE-DEV] [PATCH] procd: Restore respawn on SIGTERM timeout

John Crispin john at phrozen.org
Thu Jan 4 04:49:07 PST 2018



On 04/01/18 13:17, Kristian Evensen wrote:
> On Thu, Oct 19, 2017 at 3:02 PM, Kristian Evensen
> <kristian.evensen at gmail.com> wrote:
>> When SIGTERM times out, procd sends SIGKILL and then restarts the
>> process once SIGCHLD has been received. This all works fine, with one
>> exception - respawn is not restored when instance_start() is called from
>> instance_exit(). The reason is that respawn is always set to false in
>> instance_stop(), and the same service_instance struct is used for the
>> instance_start()-call.
>>
>> The consequence is that if the process is killed/crashes again, it will
>> not respawn. Solve this issue by adding a variable used to store the
>> original value of respawn in instance_stop(), and then restore the
>> original respawn-value in instance_exit().
>>
>> Signed-off-by: Kristian Evensen <kristian.evensen at gmail.com>
>> ---
> Ping on this patch :)
>
> -Kristian
>
Hi Kristian,

its still on my todo list. the bug is confirmed i just dont like the 
solution. however i have so far failed to come up with a better more 
generic one. i'll give it another shot the next few days

     John



More information about the Lede-dev mailing list