- What we know
- What we've created
- Hints and Kinks
- Checking Corosync cluster membership
- Configuring radosgw to behave like Amazon S3
- Downgrading to DRBD 8.3
- Fencing in Libvirt/KVM virtualized cluster nodes
- Fencing in VMware virtualized Pacemaker nodes
- GFS2 in Pacemaker (Debian/Ubuntu)
- Interleaving in Pacemaker clones
- Maintenance in active Pacemaker clusters
- Managing cron jobs with Pacemaker
- Mandatory and advisory ordering in Pacemaker
- Migrating virtual machines from block-based storage to RADOS/Ceph
- Network connectivity check in Pacemaker
- OCFS2 in Pacemaker (Debian/Ubuntu)
- Solid-state drives and Ceph OSD journals
- Solve a DRBD split-brain in 4 steps
- Testing Pacemaker clusters
- Totem "Retransmit List" in Corosync
- Turning Ceph RBD Images into SAN Storage Devices
- Which OSD stores a specific RADOS object?
- Presentations
- Ceph Tutorial (LCA 2013)
- Ceph: The Storage Stack for OpenStack (OpenStack Israel 2013)
- Die eigene Cloud mit OpenStack Essex (German, LinuxTag 2012)
- Fencing (LCE 2011)
- GlusterFS in HA Clusters (LCEU 2012)
- GlusterFS und Ceph (German, CeBIT 2012)
- Hands-On With Ceph (LCEU 2012)
- High Availability Update (OpenStack Summit Fall 2012)
- High Availability in OpenStack (CloudOpen 2012)
- High Availability in OpenStack (OpenStack Conference Spring 2012)
- Highly Available Cloud: Pacemaker integration with OpenStack (OSCON 2012)
- Mit OpenStack zur eigenen Cloud (German, CLT 2012)
- Mit OpenStack zur eigenen Cloud (German, OSDC 2012)
- More Reliable, More Resilient, More Redundant (OpenStack Summit April 2013)
- MySQL HA Deep Dive (MySQL Conference 2012)
- MySQL High Availability Deep Dive (PLUK 2012)
- MySQL High Availability Sprint (PLUK 2011)
- OpenStack Essex im Praxistest (German, Linuxwochen Wien 2012)
- OpenStack High Availability Update (Grizzly and Havana)
- Roll Your Own Cloud (LCA 2011)
- Storage Replication in HPHA (LCA 2012)
- Zen of Pacemaker (LCA 2012)
- hastexo in 100 Seconds
- Technical documentation
- News releases
- Hints and Kinks
- What we charge
- What others say

Mandatory and advisory ordering in Pacemaker
Ever wonder what's the difference between order <name> inf: <first-resource> <second-resource> and a score of something other than inf? We'll explain.
If you specify an order constraint score of INFINITY (inf or the keyword mandatory in crm shell syntax), then the order constraint is considered mandatory. If you specify 0, or the keyword advisory then it's advisory. What does that mean?
Firstly, anytime two resources are started in the same cluster transition, order constraints do apply regardless of whether they're mandatory or advisory. So for the two constraints shown here:
order o_foo_before_bar inf: foo bar order o_foo_before_bar 0: foo bar
... if foo and bar are just starting, foo starts first, and bar starts only when foo's start operation is completed. So what's the difference, really?
Mandatory ordering
In a mandatory order constraint, the order is enforced under all circumstances. Consider the following example (primitive definitions omitted to keep this short):
order o_foo_before_bar inf: foo bar
Suppose foo fails. Now foo must be recovered, but before that, bar must also stop. So the sequence of events is:
foofails- Pacemaker attempts to stop
fooagain (to make sure it's cleaned up). barstops.foostartsbarstarts.
If foo fails to start back up, then bar will remain stopped. Based on the start-failure-is-fatal and migration-threshold settings both resources can now potentially migrate to other nodes, but if foo can't be started anywhere, bar also remains stopped.
Advisory ordering
In an advisory order constraint, the order is enforced only if both resources start in the same transition. Otherwise, it's ignored. Consider the following example (primitive definitions again omitted):
order o_foo_before_bar 0: foo bar
Again, suppose foo fails. foo must be recovered, but now bar can keep running as it's not being started in the same transition. Thus:
foofails- Pacemaker attempts to stop
fooagain (to make sure it's cleaned up). foostarts
If foo fails to start back up, then bar can continue to run. Still, based on the start-failure-is-fatal and migration-threshold settings applying to foo, either it or both resources (depending on colocation constraints) can potentially migrate to other nodes.
So when do I use which?
Advisory ordering is good for when your dependent resource can recover from a brief interruption in the resource it depends on. For example, you'll want to fire up your libvirt daemon before you start your Pacemaker-managed virtual machines, but if libvirtd were ever to crash you can restart it without needing to restart VMs.
Mandatory ordering is for stricter dependencies. Filesystems mounted from an iSCSI device will probably want to be remounted if the iSCSI initator has reported an error. Likewise, you'll probably also want to restart the applications working with that filesystem.
- Anmelden oder Registrieren um Kommentare zu schreiben

Kommentare
Order reversal on stop
One additional point of clarification. In a constraint like
foostarts beforebar, and converselybarstops beforefoo. This is called symmetrical ordering. The name,o_foo_before_bar, is just a helpful mnemonic derived from the order of the start operations.