initscript: handle spaces in option values inserted into $CTDB_OPTIONS.
authorMartin Schwenke <martin@meltin.net>
Fri, 22 Jan 2010 02:19:00 +0000 (13:19 +1100)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Fri, 22 Jan 2010 04:34:21 +0000 (15:34 +1100)
commit522fbb012524fe41a67dbe43589a282dda6bcbe2
tree4b9d7d57125a15ec35f54909f61c64aa786ccc91
parent60aa570aaa77d293b963105b3f605f9625a4594b
initscript: handle spaces in option values inserted into $CTDB_OPTIONS.

This puts single quotes around everything and uses eval on the
command-lines that actually start ctdbd.  The eval causes the single
quotes to be interpreted.

The "redhat" init style no longer uses the Red Hat daemon function.
It loses the quoting and re-splits on spaces.  Instead we add an extra
line that uses the success/failure functions to keep things pretty.
Note that this means that we don't respect daemon's
$DAEMON_COREFILE_LIMIT variable but we do our own core file handling
with $CTDB_SUPPRESS_COREFILE anyway.  daemon's core file handling was
probably overriding what we were doing anyway, so this can be regarded
as a bug fix.

Signed-off-by: Martin Schwenke <martin@meltin.net>
config/ctdb.init