[Linux-HA] Migrate a resource depending on another resources fail count

Dan Searle dan.searle at censornet.com
Wed Jul 29 09:51:15 MDT 2009


Hi,

In sort:
I want to configure heartbeat 2.1.3 (in CIB mode) to migrate a resource 
to another node if another resource fails multiple times within a short 
time period.

Detail:
I have a floating IP address using an IPaddr resource shared between two 
nodes which are both running a cloned TCP server service (a proxy server 
to be precise). So in normal operation the proxy resource runs on both 
nodes, and if one goes down the floating IP is re-assigned to the other 
node, this works fine.

However, I want the floating IP to migrate to the other node if the 
proxy resource fails multiple times, say fail count is >= 4 times in 1 
hour. I can reset the fail count ever hour on a cron job using something 
like:

    crm_failcount -U /node_where_failure_occurred/ -r 
/resource_that_failed/ -D

But how to I set up the constraints so that the IPaddr resource migrates 
depending on the cloned proxy resource's fail count?

Regards, Dan...





------------------------------------------------------------------------------------
Scanned for viruses, spam and offensive content by CensorNet MailSafe

Try CensorNet free for 14 days. Provide Internet access on your terms.
Visit www.censornet.com for more information.



More information about the Linux-HA mailing list