« Previous | Next » 

Revision 82cd7760

ID82cd7760226f186a16cc3cb84506cc1b81f2f559

Added by Iustin Pop over 14 years ago

Improve the example startup script

Currently, the supplised script has two issues:
- it doesn't use start-stop-daemon --start correctly, leading to
messages like "ganeti.errors.GenericError:
/var/run/ganeti/ganeti-rapi.pid contains a live process" in the logs
- it doesn't allow start/stop/restart of a single daemon, which leads
to manual launch, which is bad because we don't reuse the settings
from the defaults file

For the first one, we change from ‘--exec …’ to ‘--startas …’, which is
the actual option used for start, whereas exec is a test (that also
supplies the default to startas). We also add ‘--oknodo’ as per recent
Debian policy changes.

For the second, we do a bigger change; we basically remove the full-path
and pid variables, and construct these two from the daemon name. We then
check if we are given a daemon name (in which case we only do that)
otherwise we do the requested action on all daemons.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

Files

  • added
  • modified
  • copied
  • renamed
  • deleted

View differences