[Pacemaker] Monitor process, migrate only ip resources

Andreas Kurz andreas at hastexo.com
Tue Feb 19 09:35:55 EST 2013


On 2013-02-19 13:54, Grant Bagdasarian wrote:
> Hello,
> 
>  
> 
> I wish to monitor a certain running process and migrate floating IP
> addresses when this process stops running.
> 
>  
> 
> My current configuration is as following:
> 
> crm(live)configure# show
> 
> node $id="8fe81814-6e85-454f-b77b-5783cc18f4c6" proxy1
> 
> node $id="ceb5c90f-ee6a-44b9-b722-78781f6a61ab" proxy2
> 
> primitive sip_ip ocf:heartbeat:IPaddr \
> 
>         params ip="10.0.0.1" cidr_netmask="255.255.255.0" nic="eth1" \
> 
>         op monitor interval="40s" timeout="20s"
> 
> primitive sip_ip_2 ocf:heartbeat:IPaddr \
> 
>         params ip="10.0.0.2" cidr_netmask="255.255.255.0" nic="eth1" \
> 
>         op monitor interval="40s" timeout="20s"
> 
> primitive sip_ip_3 ocf:heartbeat:IPaddr \
> 
>         params ip="10.0.0.3" cidr_netmask="255.255.255.0" nic="eth1" \
> 
>         op monitor interval="40s" timeout="20s"
> 
> location sip_ip_pref sip_ip 100: proxy1
> 
> location sip_ip_pref_2 sip_ip_2 101: proxy1
> 
> location sip_ip_pref_3 sip_ip_3 102: proxy1
> 
> property $id="cib-bootstrap-options" \
> 
>         dc-version="1.0.8-042548a451fce8400660f6031f4da6f0223dd5dd" \
> 
>         cluster-infrastructure="Heartbeat" \
> 
>         stonith-enabled="false"
> 
>  
> 
> Couple days ago our kamailio process stopped and the ip resources
> weren’t migrated to our secondary node.
> 
> The secondary node already has the kamailio process running.
> 
>  
> 
> How do I configure ha so that the kamailio process is monitored every x
> seconds and when it has stopped the three ip addresses are migrated to
> the secondary node?

Either let Pacemaker manage kamailio as a clone resource or add it as
unmanaged clone resource only ... either way you then need to colocate
the ip adresses with that clone to run only where a kamailio clone
instance is up.

Regards,
Andreas

-- 
Need help with Pacemaker?
http://www.hastexo.com/now


> 
>  
> 
> Grant
> 
> 
> 
> _______________________________________________
> Pacemaker mailing list: Pacemaker at oss.clusterlabs.org
> http://oss.clusterlabs.org/mailman/listinfo/pacemaker
> 
> Project Home: http://www.clusterlabs.org
> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://bugs.clusterlabs.org
> 







More information about the Pacemaker mailing list