[Linux-HA] Handling colocation constraints with more than 2 entries

Lars Marowsky-Bree lmb at novell.com
Thu Oct 7 09:49:05 MDT 2010

On 2010-10-05T18:03:17, Andrew Beekhof <andrew at beekhof.net> wrote:

> > Anyway, it's too late to change the semantics as
> > that would change behaviour of the existing clusters.
> Actually the solution is really quite easy.
> 1. Make constraints with > 2 elements and no/insufficient brackets
> produce a warning and require user confirmation.
> There is certainly precedent for things in the shell becoming warnings
> that weren't previously.
> 2. Decide on two types of brackets to use, one for ordered and one for
> unordered.

Admittedly, I find the whole notion of "ordered" collocation extremely
annoying, and unclean design. I'd much rather not have the shell support
that at all.

That collocation is expressed in what amounts to the reverse of the
"natural" consequence of ordering is a bit confusing, but I'm afraid
we're stuck with that now.

For order + colocation, a rather common combination of constraints, what
I'd rather have the shell do is detect a match between them and merge
them in the shell syntax - there's no reason why a shell statement
_must_ only expand to a single XML element.


order foo inf: a b
colocation bar inf: b a

would be merged to

join foo: inf: a b

in the shell. And then do the same for sets; it's not much more
difficult, and we'll all be much cleaner off than with trying to
remember what the heck [] () {} were about. And keep it at one set of

(Add an expand command to turn the automated merge of if people want to
etc etc, but you get the idea.)


Architect Storage/HA, OPS Engineering, Novell, Inc.
SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg)
"Experience is the name everyone gives to their mistakes." -- Oscar Wilde

More information about the Linux-HA mailing list