Hi,
I have the following problem.
I am using heartbeat 2.1.2
I have an IP address resource and a another resource RES_X.
Two nodes Node A and Node B
In my Active Passive configuration, I will have the RES_X up all the
time on both servers.
The Failover or heartbeat startup would have to run a reload command on
this resource. So in the OCF RA script for RES_X, I have a reload
command of that resource when start is called. And stop of this resource
does not do anything but return success.
My deafault failure stickiness is -100 and default resource stickiness
is 300
RES_X has a score of 250, with preferred location as Node A
When the RES_X is down on node A, it fails over to node B , and that's
great.
But When I fix the failure on node A and kill the resource RES_X on node
B, I need the IP address and RES_X start ( that is, start called but
reload is executed) to happen on node A.
This does not happen.
I ran ptest,
I see the scores are set to -1000000 on both nodes.
I try running failcount reset, still does not work. Scores are not
reset.
How can I make the failback to Node A happen ?
Ptest output is below :
ptest[10530]: 2007/09/26_07:03:37 debug: unpack_config: STONITH of
failed nodes is disabled
ptest[10530]: 2007/09/26_07:03:37 debug: unpack_config: Cluster is
symmetric - resources can run anywhere by default
ptest[10530]: 2007/09/26_07:03:37 debug: unpack_config: On loss of CCM
Quorum: Stop ALL resources
ptest[10530]: 2007/09/26_07:03:37 info: determine_online_status: Node
roopa2 is online
ptest[10530]: 2007/09/26_07:03:37 WARN: unpack_rsc_op: Processing failed
op (qip-named_2_start_0) on roopa2
ptest[10530]: 2007/09/26_07:03:37 WARN: unpack_rsc_op: Handling failed
start for qip-named_2 on roopa2
ptest[10530]: 2007/09/26_07:03:37 info: determine_online_status: Node
roopa1 is online
ptest[10530]: 2007/09/26_07:03:37 WARN: unpack_rsc_op: Processing failed
op (qip-named_2_start_0) on roopa1
ptest[10530]: 2007/09/26_07:03:37 WARN: unpack_rsc_op: Handling failed
start for qip-named_2 on roopa1
ptest[10530]: 2007/09/26_07:03:37 info: group_print: Resource Group:
group_1
ptest[10530]: 2007/09/26_07:03:37 info: native_print: IPaddr_cluster
(heartbeat::ocf:IPaddr): Stopped
ptest[10530]: 2007/09/26_07:03:37 info: native_print: qip-named_2
(heartbeat::ocf:qip-named): Stopped
ptest[10530]: 2007/09/26_07:03:37 info: native_print: qip-named_2
(heartbeat::ocf:qip-named): Stopped
ptest[10530]: 2007/09/26_07:03:37 debug: group_rsc_location: Processing
rsc_location prefered_location_group_1 for group_1
ptest[10530]: 2007/09/26_07:03:37 debug: native_print: Allocating:
IPaddr_cluster (heartbeat::ocf:IPaddr): Stopped
ptest[10530]: 2007/09/26_07:03:37 debug: native_assign_node: Color
IPaddr_cluster, Node[0] roopa2: -1000000
ptest[10530]: 2007/09/26_07:03:37 debug: native_assign_node: Color
IPaddr_cluster, Node[1] roopa1: -1000000
ptest[10530]: 2007/09/26_07:03:37 debug: native_assign_node: All nodes
for resource IPaddr_cluster are unavailable, unclean or shutting down
ptest[10530]: 2007/09/26_07:03:37 WARN: native_color: Resource
IPaddr_cluster cannot run anywhere
ptest[10530]: 2007/09/26_07:03:37 debug: native_print: Allocating:
qip-named_2 (heartbeat::ocf:qip-named): Stopped
ptest[10530]: 2007/09/26_07:03:37 debug: native_assign_node: Color
qip-named_2, Node[0] roopa2: -1000000
ptest[10530]: 2007/09/26_07:03:37 debug: native_assign_node: Color
qip-named_2, Node[1] roopa1: -1000000
ptest[10530]: 2007/09/26_07:03:37 debug: native_assign_node: All nodes
for resource qip-named_2 are unavailable, unclean or shutting down
ptest[10530]: 2007/09/26_07:03:37 WARN: native_color: Resource
qip-named_2 cannot run anywhere
ptest[10530]: 2007/09/26_07:03:37 debug: update_action: Ignoring
implies left - qip-named_2 already stopped
ptest[10530]: 2007/09/26_07:03:37 debug: update_action: * Marking
action group_1_start_0 un-runnable because of IPaddr_cluster_start_0
ptest[10530]: 2007/09/26_07:03:37 debug: init_dotfile: PE_DOT: digraph
"g" {
ptest[10530]: 2007/09/26_07:03:37 debug: main: PE_DOT: }
ptest[10530]: 2007/09/26_07:03:37 info: unpack_graph: Unpacked
transition 0: 0 actions in 0 synapses
ptest[10530]: 2007/09/26_07:03:37 info: set_default_graph_functions:
Setting default graph functions
ptest[10530]: 2007/09/26_07:03:37 debug: run_graph:
====================================================
ptest[10530]: 2007/09/26_07:03:37 info: run_graph: Transition 0:
(Complete=0, Pending=0, Fired=0, Skipped=0, Incomplete=0)
~
[EMAIL PROTECTED] ~]# crm_failcount -D -U roopa1 -r qip-named_2
crm_failcount[10532]: 2007/09/26_07:04:05 info: Invoked: crm_failcount
-D -U roopa2 -r qip-named_2
[EMAIL PROTECTED] ~]# crm_failcount -G -U roopa1 -r qip-named_2
crm_failcount[10533]: 2007/09/26_07:04:07 info: Invoked: crm_failcount
-G -U roopa2 -r qip-named_2
name=fail-count-qip-named_2 value=0
[EMAIL PROTECTED] ~]#
Snippet of the OCF script :
prog=named
start() {
echo -n $"Reloading $prog: "
if [ -n "`pidofproc $prog`" ]; then
echo -n $"$prog: running"
reload
return $?
else
echo -n $"$prog: not running"
failure
return 1
fi
}
stop() {
echo -n $"stop $prog called, returning without stopping
$prog "
return $OCF_SUCCESS
}
rndcstatus() {
$xxx $xxxOPTIONS status >/dev/null 2>&1
rc=$?
if [ $rc -eq 1 ]; then
return 7
fi
return $rc
}
restart() {
stop
sleep 3
start
}
reload() {
echo -n $"Reloading $prog: "
$xxx $xxxOPTIONS reload >/dev/null 2>&1
RETVAL=$?
echo
return $RETVAL
}
Thanks,
Roopa
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems