Combining and ordering related actions
There are two final pieces of the puzzle that will produce a fully functional Pacemaker cluster. At this point, we have three independent base-level entries in Pacemaker: DRBD, the PGServer
group, and the e-mail alert. They are independent because Pacemaker may start or stop them on any server in the list of active nodes.
We can fix this by defining a colocation between related resources. When we create a colocation, we are effectively stating that wherever this service goes, this other service should follow. Of course, this by itself is not sufficient. We also need to declare the expected order necessary for the services to start.
In this recipe, we'll finish our Pacemaker setup by creating necessary colocation entries, and define a service start order.
Getting ready
As we're continuing to configure Pacemaker, make sure that you've followed all the previous recipes.
How to do it...
Perform these steps on any Pacemaker node as the root
user...