[Linux-HA] Master-slave, stopping a slave.

Dominik Klein dk at in-telegence.net
Wed Jul 8 05:48:01 MDT 2009


c smith wrote:
> Dominik-
> 
> Thanks for the reply.. I'm aware that the documents advise against it, but
> surely there must be a way.  I was just looking at the new DRBD 8.3.2.  It
> includes a fencing handler script that, upon failure of a DRBD master, adds
> a -INFINITY location constraint into the CIB that prevents the MS resource
> from being 'Master' on the failed node until resync/uptodate (at which point
> its deleted from the CIB)
> 
> Pasted from ./drbd-8.3.2/scripts/crm-fence-peer.sh:
> 
> new_constraint="\
> <rsc_location rsc=\"$master_id\" id=\"$id_prefix-$master_id\">
>   <rule role=\"Master\" score=\"-INFINITY\"
> id=\"$id_prefix-rule-$master_id\">
>     <expression attribute=\"$fencing_attribute\" operation=\"ne\"
> value=\"$fencing_value\" id=\"$id_prefix-expr-$master_id\"/>
>   </rule>
> </rsc_location>"
> 
> This constraint, when in place, succesfully stops the child from running on
> that node.  Wondering if it is possible to do the same with the slave
> resource.
> 
> I will also try out unmanage'ing the resource and see if that will
> accomplish similar. 

It will not stop the slave. It will unmanage the entire m/s drbd
resource, meaning the cluster will no longer monitor its status. So if
you disconnect drbd and do your backup business of whatever kind, the
cluster will not notice. Then you can re-connect drbd and let pacemaker
manage the resource again.

Regards
Dominik



More information about the Linux-HA mailing list