Re: runit kill runsv

From: Colin Booth <cathexis_at_gmail.com>
Date: Wed, 22 Jun 2016 18:37:38 -0700

On Jun 22, 2016 5:39 PM, "Thomas Lau" <tlau <tlau_at_tetrioncapital.com>_at_
<tlau_at_tetrioncapital.com>tetrioncapital.com <tlau_at_tetrioncapital.com>>
wrote:
>
> here is the run script:
>
> #!/bin/sh
> exec 2>&1
> echo "*** Starting service ..."
> RUNASUSER="tlau"
> RUNASUID=$(getent passwd $RUNASUSER | cut -d: -f3)
> RUNASGROUPS=$(id -G $RUNASUSER | tr ' ' ':')
> exec chpst -u :$RUNASUID:$RUNASGROUPS /usr/bin/memcached -vvv -m 64
>
Your runscript seems ok, I'd probably do the user lookup differently but
that's mostly a style thing.
>
> I just tested -P, doesn't help and I could kill runsv process, memcached
daemon still running.
>
> I know OOM might not kill it, just trying to simulate what happen, who
knows when I was working on a system at 3AM in the morning and accidentally
kill runsv? :) I want to find out how is runit fault tolerance level.

Oh, it sounded like you were having real issues. Runsv (and the rest of the
runit suite) should stay functional well after the rest of the system has
been run into the ground. As long as you avoid issuing a "killall -9 runsv"
or something equally catastrophic you should be ok. Generally speaking, as
long as you use the sv command instead of direct signaling, you're good to
go. In my history of using supervision-heavy systems and getting paged
awake at 3 AM, screwing up the supervisor is low on my list of mistakes.

Cheers!
-Colin
Received on Thu Jun 23 2016 - 01:37:38 UTC

This archive was generated by hypermail 2.3.0 : Sun May 09 2021 - 19:44:19 UTC