Hi, On Thu, Mar 26, 2009 at 02:19:32PM +0530, Arun G wrote: > > From: Dejan Muhamedagic <[email protected]> > > Subject: Re: [Linux-HA] drbd RA issue in (heartbeat 2.1.4 + > > ? ? ? ?drbd-8.3.0) > > To: General Linux-HA mailing list <[email protected]> > > Message-ID: <[email protected]> > > Content-Type: text/plain; charset="us-ascii" > > > > Hi, > > > > On Thu, Mar 19, 2009 at 01:21:30PM +0100, Dominik Klein wrote: > >> Dejan Muhamedagic wrote: > >> > Hi, > >> > > >> > On Wed, Mar 18, 2009 at 11:37:27AM -0700, Neil Katin wrote: > >> >> > >> >> Dejan Muhamedagic wrote: > >> >>> Hi, > >> >>> > >> >>> On Tue, Mar 17, 2009 at 11:56:04AM +0530, Arun G wrote: > >> >>>> Hi, > >> >>>> ? ? ?I observed below error message when I upgraded drbd to > >> >>>> drbd-8.3.0 in > >> >>>> heartbeat 2.1.4 cluster on 2.6.18-8.el5xen. > >> >> -- snip -- > >> >> > >> >>> Thanks for the patch. But do all supported drbd versions have the > >> >>> role command? > >> >>> > >> >>> Thanks, > >> >>> > >> >>> Dejan > >> >> No, only 8.3 has the change. ?8.2 supports the old "state" argument, but > >> >> prints a warning message out, and this warning message upsets the drbd > >> >> OCF > >> >> scripts parting of drbdadm's output. > >> > > >> > Since versions before 8.3 don't have the role command, I suppose > >> > that 8.3 actually prints the warning. > >> > > >> >> drbdadm doesn't support a --version argument, but it does support a > >> >> "status" > >> >> command, which has version info in it. ?However, I am not sure if > >> >> "drbdadm status" > >> >> is guaranteed to not block or not, so I didn't want to have the OCF > >> >> script depend > >> >> on it. > >> > > >> > drbdadm ?| grep Version > >> > > >> > works for 8.2.7 and 8.0.14, so I guess that it is available in > >> > other versions too. > >> > > >> >> So, I see three alternatives: add a new script "drbdadm8.3". ?Add an > >> >> extra parameter > >> >> saying "use role instead of status". ?Or call "drbdadm status" to > >> >> dynamically detect > >> >> our version. > >> >> > >> >> Do you see other choices? ?Do you have a preference for a particular > >> >> alternative? > >> >> I'm willing to code and test the patch if we can decide what we want. > >> > > >> > Let's see if we can figure out the version. Adding new RA would > >> > be a maintenance issue. Adding new parameter would make > >> > configuration depend on particular release. > >> > > >> > We could do something like this: > >> > > >> > drbdadm ?| grep Version | awk '{print $2}' | > >> > awk -F. ' > >> > ? ? $1 != 8 { exit 2; } > >> > >> This should also allow version 7. People may still use v7. The drbdadm | > >> grep thing also works. Tested with latest v7 in a vm. > >> > >> It prints > >> > >> # drbdadm ?| grep Version | awk '{print $2}' > >> 0.7.25 > >> > >> though. > > > > OK. Can somebody please test the patch (attached). > > > Hello Dejan, > A small correction is required at line No. 33 of this patch. > This line should be "echo state" instead of "echo status"
OK. > I have tested it with drbd.8.3.0, drbd.8.2.7 and drbd.0.7.25 versions > and found it working properly. Many thanks for testing. Cheers, Dejan > Regards, > Arun. > > Thanks, > > > > Dejan > > > >> Regards > >> Dominik > > -------------- next part -------------- > > A non-text attachment was scrubbed... > > Name: drbd.patch > > Type: text/x-patch > > Size: 1120 bytes > > Desc: not available > > Url : > > http://lists.community.tummy.com/pipermail/linux-ha/attachments/20090324/764d4076/drbd-0001.bin > > > _______________________________________________ > 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
