8.7. Ensuring Time Based Rules Take Effect
A Pacemaker cluster is an event driven system. As such, it won’t recalculate the best place for resources to run in unless something (like a resource failure or configuration change) happens. This can mean that a location constraint that only allows resource X to run between 9am and 5pm is not enforced.
If you rely on time based rules, it is essential that you set the cluster-recheck-interval
option. This tells the cluster to periodically recalculate the ideal state of the cluster. For example, if you set cluster-recheck-interval=5m
, then sometime between 9:00 and 9:05 the cluster would notice that it needs to start resource X, and between 17:00 and 17:05 it would realize that X needed to be stopped.
Note that the timing of the actual start and stop actions depends on what else needs to be performed first .