Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Lars Marowsky-Bree wrote: On 2007-04-05T08:46:40, Alan Robertson [EMAIL PROTECTED] wrote: My only comment on this is that if having two copies of your resource agent running at once causes serious problems, you need to _strongly_ consider re-writing you agent to have sufficient locking / atomicity. Or it will come back to bite you some day... This is the job of the Heartbeat infrastructure - to ensure that this never happens. This is not true as such. We ensure that the same resource instance never has more than 1 concurrent execution going, but there can be several instances with the same type. In short, we don't serialize on resource type+class, but on rsc id. Thanks for making that clearer. I thought that's what was being asked about, but was a little sloppy in my answer. -- Alan Robertson [EMAIL PROTECTED] Openness is the foundation and preservative of friendship... Let me claim from you at all times your undisguised opinions. - William Wilberforce ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
On 2007-04-05T08:46:40, Alan Robertson [EMAIL PROTECTED] wrote: My only comment on this is that if having two copies of your resource agent running at once causes serious problems, you need to _strongly_ consider re-writing you agent to have sufficient locking / atomicity. Or it will come back to bite you some day... This is the job of the Heartbeat infrastructure - to ensure that this never happens. This is not true as such. We ensure that the same resource instance never has more than 1 concurrent execution going, but there can be several instances with the same type. In short, we don't serialize on resource type+class, but on rsc id. Now, with clones, each clone instance is a separate id, so they get executed in parallel. ordered serializes them at the very highest level - which is stronger than required. What's actually required here would be an ordered=node setting to order the invocations on a given clone per node. (And maybe even make that the default.) Anyone going to file a bugzilla enhancement request? ;-) Sincerely, Lars -- Teamlead Kernel, SuSE Labs, Research and Development SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) Experience is the name everyone gives to their mistakes. -- Oscar Wilde ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
[Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Hi, Can a RA script know if the clone resource has set ordered=true or interleave=true? Is this information somewhere set in a variable, like the OCF_RESKEY_CRM_meta_clone_max for the information about maximum number of clones in a resource? Thanks. -- Dr. Michael Schwartzkopff MultiNET Services GmbH Addresse: Bretonischer Ring 7; 85630 Grasbrunn; Germany Tel: +49 - 89 - 45 69 11 0 Fax: +49 - 89 - 45 69 11 21 mob: +49 - 174 - 343 28 75 mail: [EMAIL PROTECTED] web: www.multinet.de Sitz der Gesellschaft: 85630 Grasbrunn Registergericht: Amtsgericht München HRB 114375 Geschäftsführer: Günter Jurgeneit, Hubert Martens --- PGP Fingerprint: F919 3919 FF12 ED5A 2801 DEA6 AA77 57A4 EDD8 979B Skype: misch42 ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
On 4/5/07, Michael Schwartzkopff [EMAIL PROTECTED] wrote: Hi, Can a RA script know if the clone resource has set ordered=true or interleave=true? Is this information somewhere set in a variable, like the OCF_RESKEY_CRM_meta_clone_max for the information about maximum number of clones in a resource? i think they're filtered out - did you try adding a call to env in your script? if set, they whould be set as OCF_RESKEY_CRM_meta_interleave and OCF_RESKEY_CRM_meta_ordered more importantly though... why do you need them? Thanks. -- Dr. Michael Schwartzkopff MultiNET Services GmbH Addresse: Bretonischer Ring 7; 85630 Grasbrunn; Germany Tel: +49 - 89 - 45 69 11 0 Fax: +49 - 89 - 45 69 11 21 mob: +49 - 174 - 343 28 75 mail: [EMAIL PROTECTED] web: www.multinet.de Sitz der Gesellschaft: 85630 Grasbrunn Registergericht: Amtsgericht München HRB 114375 Geschäftsführer: Günter Jurgeneit, Hubert Martens --- PGP Fingerprint: F919 3919 FF12 ED5A 2801 DEA6 AA77 57A4 EDD8 979B Skype: misch42 ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Am Donnerstag, 5. April 2007 13:52 schrieb Andrew Beekhof: On 4/5/07, Michael Schwartzkopff [EMAIL PROTECTED] wrote: Hi, Can a RA script know if the clone resource has set ordered=true or interleave=true? Is this information somewhere set in a variable, like the OCF_RESKEY_CRM_meta_clone_max for the information about maximum number of clones in a resource? i think they're filtered out - did you try adding a call to env in your script? if set, they whould be set as OCF_RESKEY_CRM_meta_interleave and OCF_RESKEY_CRM_meta_ordered more importantly though... why do you need them? iptables CLUSTERIP target, which I use for load sharing, is VERY sensitive to the order which the commands are used. If I use a non-ordered clone resource it happens that two or more rules are created in the input chain, chains are not deleted correctly during stop, or the ipt_CLUSTERIP kernel module is not removed, which is really bad. At the moment load sharing works with an ordered clone resource. Before I publish my script I want to validate, that the ordered is really set and the user did not configure nonsense which might crash the system. If I find some time it might be interesting to add the feature to the RA to be used in an non-ordered enviroment. -- Dr. Michael Schwartzkopff MultiNET Services GmbH Addresse: Bretonischer Ring 7; 85630 Grasbrunn; Germany Tel: +49 - 89 - 45 69 11 0 Fax: +49 - 89 - 45 69 11 21 mob: +49 - 174 - 343 28 75 mail: [EMAIL PROTECTED] web: www.multinet.de Sitz der Gesellschaft: 85630 Grasbrunn Registergericht: Amtsgericht München HRB 114375 Geschäftsführer: Günter Jurgeneit, Hubert Martens --- PGP Fingerprint: F919 3919 FF12 ED5A 2801 DEA6 AA77 57A4 EDD8 979B Skype: misch42 ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Michael Schwartzkopff wrote: Am Donnerstag, 5. April 2007 15:35 schrieb Alan Robertson: So, at the moment, you really just want to make sure you're configured correctly. Is that right? Yes. My only comment on this is that if having two copies of your resource agent running at once causes serious problems, you need to _strongly_ consider re-writing you agent to have sufficient locking / atomicity. Or it will come back to bite you some day... -- Carson ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Alan Robertson wrote: Carson Gaspar wrote: My only comment on this is that if having two copies of your resource agent running at once causes serious problems, you need to _strongly_ consider re-writing you agent to have sufficient locking / atomicity. Or it will come back to bite you some day... This is the job of the Heartbeat infrastructure - to ensure that this never happens. I think having us enforce these rules in one place is much cheaper than trying to enforce it everywhere. Indeed, we spend a lot of effort making sure that this doesn't happen even in corner cases. Are you suggesting that every resource agent duplicate that? I actually wasn't aware that the guarantee was that strong (except where interleaved is specified?) It all depends on how bad the consequences of failure are, and how expensive the insurance is. And I tend to lean toward the trust, but verify school, being from an InfoSec background. -- Carson ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Carson Gaspar schrieb: My only comment on this is that if having two copies of your resource agent running at once causes serious problems, you need to _strongly_ consider re-writing you agent to have sufficient locking / atomicity. Or it will come back to bite you some day... Hi, have running two or more copies of the clone resources on one node is no problem. Only the start and the stop of the resources has to be ordered. If two resources are started at the same time they interfere during start which leaves the node in an undefined state. ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems
Re: [Linux-HA] Can a RA know if a clone resource is ordered or interleave is true?
Carson Gaspar wrote: Alan Robertson wrote: Carson Gaspar wrote: My only comment on this is that if having two copies of your resource agent running at once causes serious problems, you need to _strongly_ consider re-writing you agent to have sufficient locking / atomicity. Or it will come back to bite you some day... This is the job of the Heartbeat infrastructure - to ensure that this never happens. I think having us enforce these rules in one place is much cheaper than trying to enforce it everywhere. Indeed, we spend a lot of effort making sure that this doesn't happen even in corner cases. Are you suggesting that every resource agent duplicate that? I actually wasn't aware that the guarantee was that strong (except where interleaved is specified?) It all depends on how bad the consequences of failure are, and how expensive the insurance is. And I tend to lean toward the trust, but verify school, being from an InfoSec background. I understand. But the problem is actually quite hard to do right. It involves things like quorum, and fencing and some design and implementation in the LRM. We are pretty paranoid about this - so you don't have to be. The OCF spec requires that conforming implementations guarantee that operations on the same resource are strictly serialized. [The LSB doesn't consider the problem, but basically all init scripts assume serialization anyway ;-)]. We try really hard to do that. Far harder than a shell script has any business trying to do. The only sort-of-exception is if an operation times out, and we kill the process that's doing the work. It is possible that some instance of something is still hanging out there somewhere doing something when we try and start the next operation on that resource. But, there's not much we can do about that. Well, I suppose we could reboot the machine. That would do it ;-). That's the default action if the stop of a resource fails. -- Alan Robertson [EMAIL PROTECTED] Openness is the foundation and preservative of friendship... Let me claim from you at all times your undisguised opinions. - William Wilberforce ___ Linux-HA mailing list Linux-HA@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha See also: http://linux-ha.org/ReportingProblems