如何让Pacemaker在一个组中重新启动服务

我已经安装了2台安装了Pacemaker和Corosync的机器。 在那里我有一个PostgreSQL主/从设置运行。 Master拥有一个拥有虚拟IP的资源组和两个应该在主服务器上运行的附加服务。 如果通过杀死数据库主服务器触发故障切换,则会将组中的所有服务迁移到另一个节点,这正是我期望和希望的。

然而,额外的服务将被标记为失败,当我杀了他们多数民众赞成它。 因为我只想在数据库失败的时候发生迁移,所以实际上没有问题。 但是,我希望Pacemaker重新启动这些服务,以防万一他们失败,而不仅仅是标记为失败。

我的期望是,当我将on-fail = restart标志添加到这些服务的监视器操作时,它确实会这样做,但事实并非如此。

这个小组看起来像这样:

Group: master-group Resource: VirtualIP (class=ocf provider=heartbeat type=IPaddr2) Attributes: ip=1.2.3.4 cidr_netmask=24 nic=ens1f0 Operations: start interval=0s timeout=20s (VirtualIP-start-interval-0s) stop interval=0s timeout=20s (VirtualIP-stop-interval-0s) monitor interval=30s (VirtualIP-monitor-interval-30s) Resource: additional-resource1 (class=ocf provider=heartbeat type=additional-resource1) Operations: stop interval=0s timeout=20s (additional-resource1-stop-interval-0s) monitor interval=60s timeout=20s (additional-resource1-monitor-interval-60s) start interval=0s on-fail=restart timeout=20s (additional-resource1-start-interval-0s) Resource: additional-resource2 (class=lsb type=additional-resource2) Operations: start interval=10s on-fail=restart timeout=60s (additional-resource2-start-interval-10s) stop interval=0s timeout=20s (additional-resource2-stop-interval-0s) monitor interval=60s on-fail=restart timeout=0s (additional-resource2-monitor-interval-60s) Stonith Devices: Fencing Levels: Location Constraints: Ordering Constraints: promote msPostgresql then start master-group (score:INFINITY) (non-symmetrical) (id:order-msPostgresql-master-group-INFINITY) demote msPostgresql then stop master-group (score:0) (non-symmetrical) (id:order-msPostgresql-master-group-0) Colocation Constraints: master-group with msPostgresql (score:INFINITY) (rsc-role:Started) (with-rsc-role:Master) (id:colocation-master-group-msPostgresql-INFINITY) Ticket Constraints: Alerts: No alerts defined Resources Defaults: resource-stickiness: INFINITY migration-threshold: 1 Operations Defaults: No defaults set Cluster Properties: cluster-infrastructure: corosync dc-version: 1.1.15-11.el7_3.4-e174ec8 have-watchdog: false last-lrm-refresh: 1498820659 no-quorum-policy: ignore stonith-enabled: false Node Attributes: node1: pgsql-data-status=LATEST node2: pgsql-data-status=STREAMING|SYNC 

任何人都可以解释如何做到这一点?