supervision - discussion about system services, daemon supervision, init, runlevel management, and tools such as s6 and runit
 help / color / mirror / Atom feed
From: Stefan Karrmann <S.Karrmann@web.de>
Subject: Re: Should svwaitup/down be built again, or how to make sv do this?
Date: Mon, 17 Jul 2006 21:32:00 +0200	[thread overview]
Message-ID: <20060717193200.GB26631@johann.karrmann.de> (raw)
In-Reply-To: <200607171256.14899.spamite@ev1.net>

Dear all,

due to racing conditions, you cannot guarantee that a service is active.

E.g. regard:
#! /bin/sh
svwaitup /service/foo
exec baz

After svwaitup returns with success, the service foo can crash before the
shell starts the command exec.

If foo crashes you can hope that runsv restarts it. It would be worse if
foo is in a deadlock.

Even if the control of foo is in baz or foo offers a control socket which
reports the activity of foo the racing can happen in baz itself.

Most of the time you ignore the racing conditions in Un*x.
The only formal solution is the usage of timeouts in baz together with
error handlers.

> So, it sounds like you're saying that the functionality of checking for a 
> service to be running, and waiting until that service is running before 
> continuing no longer exists in runit as it is presently built.  Is this 
> correct?

Kind regards,
-- 
Stefan Karrmann

Computer programmers never die, they just get lost in the processing.


  reply	other threads:[~2006-07-17 19:32 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-12  1:59 Kevin
2006-07-12 15:20 ` Gerrit Pape
2006-07-12 16:27   ` Kevin
2006-07-13  8:44     ` Gerrit Pape
2006-07-17 17:56       ` Kevin
2006-07-17 19:32         ` Stefan Karrmann [this message]
2006-07-18  8:38         ` Uffe Jakobsen
2006-07-19 18:46           ` Kevin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060717193200.GB26631@johann.karrmann.de \
    --to=s.karrmann@web.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).