or would it better not to increment the failcount? in unpack_rsc_op(), demote operation is checked not to go into loop, but promote is not. see attached.
Thanks, Junko 2010/10/21 Junko IKEDA <tsukishima...@gmail.com>: > Hi, > > When the promote/demote action returns error code, > it seems that failcount isn't incremented, > so promote/demote action would go into a loop in some cases. > Default settings for promote/demote are implicitly-defined > (on_fail="restart" and interval=0). > Is it possible to handle them as in the case of start/stop operation? > It means, if there are some errors about promote/demote, > pacemaker considers its interval as 1 temporarily. > see attached. > > Thanks, > Junko IKEDA > > NTT DATA INTELLILINK CORPORATION >
diff -r e7bd6392d1e3 lib/pengine/unpack.c --- a/lib/pengine/unpack.c Fri Oct 22 08:18:16 2010 +0200 +++ b/lib/pengine/unpack.c Mon Oct 25 14:45:23 2010 +0900 @@ -1831,7 +1831,8 @@ unpack_rsc_op(resource_t *rsc, node_t *n } } else if(safe_str_eq(task, CRMD_ACTION_PROMOTE)) { - rsc->role = RSC_ROLE_MASTER; + resource_location( + rsc, node, -INFINITY, "__promote_fail__", data_set); } else if(safe_str_eq(task, CRMD_ACTION_DEMOTE)) { /*
_______________________________________________ Pacemaker mailing list: Pacemaker@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://developerbugs.linux-foundation.org/enter_bug.cgi?product=Pacemaker