On Wed, Jun 25, 2008 at 19:41, Serge Dubrouski <[EMAIL PROTECTED]> wrote: >>>>>>> http://hg.linux-ha.org/dev/file/42ce605e3da5/resources/OCF/pgsql >>>>>>> >>>>>>> Look at the end of the script. >>>>>>> >>>>>>> If it is invoked in any other way, it calls usage which exits >>>>>>> OCF_ERR_ARGS >>>>>>> (ie 2). See how it was called. This should be the reason. >>>>>>> >>>>>>> I wonder how this could pass ocf-tester. It does not support any of >>>>>>> the >>>>>>> notify operations nor validate-all nor meta-data. >>>>>>> >>>>>>> Or am I looking at the wrong file? >>>>>> >>>>>> You are looking at the right file, and I submitted a patch for this >>>>>> problem a couple of weeks ago. >>>>>> >>>>> And here is one more patch that fixes the problem. Also I have a >>>>> couple of questions: >>>>> >>>>> 1. What is 'fail' operation is supposed to do? >>>> >>>> "fail" :-) >>> >>> That is to broad an explanation :-) >>> >>> I just wonder what would be the best implementation for fail action >>> in RA. In this "fixed" version pgsql just reports "NOT_IMPLEMENTED", >>> crm increases fail_count and if score still allows to keep a resource >>> on a current node nothing else happens. >> >> well it would also be restarted. >> otherwise one could just as easily use crm_failcount. >> >>> I suspect that one would >>> expect a resource to be moved from the current node when "crm_resource >>> -F" is called, but I don't know how to correctly implement that on a >>> RA level. >> >> use crm_failcount to set a value of INFINITY > > In fact I kind of disagree that an RA has to handle this.
it shouldn't. use crm_failcount. > >> >>> >>> May be the best way would if CRM not just incrased failcount but set >>> it to a value high enough for failing a resource over to another node? >> >> This is not the purpose of crm_resource -F >> If you want a resource to move, use -M > > Then what is the purpose of "-F"? As I said there is no documentation on it. as dejan said, to tell the crm that the resource failed without waiting for the next monitor > >> >>> >>> In this case RA would just stop a resource when it's called with >>> "fail" action. >> >> no - it should say "i dont support this action". >> and anyway you shouldn't rely on the RA being called at all... this was only >> a temporary fix and will be going away now that there is an LRM API call >> that the crm can use instead. > > So there is no need for an RA to support "fail" operation? Then why it > is gets called with it? precisely because it doesn't support it - to get an error. > It looks like I'm loosing and whole point of that "fail" operations. > What do you mean by an "asynchronous" fail? > > -- > Serge Dubrouski. > _______________________________________________ > Linux-HA mailing list > [email protected] > http://lists.linux-ha.org/mailman/listinfo/linux-ha > See also: http://linux-ha.org/ReportingProblems > _______________________________________________ Linux-HA mailing list [email protected] http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
