[ClusterLabs] different start/stop order

Ken Gaillot kgaillot at redhat.com
Fri Oct 27 15:30:50 EDT 2017


On Fri, 2017-10-27 at 14:35 +0200, Stefan Krueger wrote:
> Hello,
> 
> is it possible to start a ressource in a different way then they
> stopped?
> eg:
> primitive HA_IP-Serv1 IPaddr2 \
>         params ip=172.16.101.70 cidr_netmask=16 \
>         op monitor interval=20 timeout=30 on-fail=restart nic=bond0 \
>         meta target-role=Started
> primitive HA_IP-Serv2 IPaddr2 \
>         params ip=172.16.101.74 cidr_netmask=16 \
>         op monitor interval=10s nic=bond0
> primitive nc_storage ZFS \
>         params pool=nc_storage importargs="-d /dev/disk/by-
> partlabel/"
> primitive nfs-serv1 systemd:nfs-server
> primitive nfs-serv2 systemd:nfs-server
> group compl_zfs-serv1 nc_storage nfs-serv1 HA_IP-Serv1
> 
> I want that pacemaker stop it in this order:
> HA_IP-Serv1 nfs-serv1  nc_storage
> 
> but start it in this order:
> nfs-serv1 nc_storage HA_IP-Serv1
> 
> it that possible and how can I achieve that?
> 
> best regards
> Stefan

Yes. You'd have to get rid of the group (which always starts in the
listed order and stops in reverse), and instead use colocation and
ordering constraints. You can make ordering constraints asymmetrical,
so they only apply in the listed direction:

http://clusterlabs.org/doc/en-US/Pacemaker/1.1-pcs/html-single/Pacemake
r_Explained/index.html#s-resource-ordering

-- 
Ken Gaillot <kgaillot at redhat.com>




More information about the Users mailing list