[DRBD-user] DRBD + Heartbeat - Doubt after fail !

contact at gcm-solutions.com contact at gcm-solutions.com
Tue Aug 31 20:17:15 CEST 2004


Quoting Lars Ellenberg <Lars.Ellenberg at linbit.com>:

> > Hello Lars.
> >
> > I think i was not clear with my question !
> >
> > DRBD is already on my init process ! It loads before heartbeat !  The
> > 2 nodes are ok with DRBD when i turn then on !! They syncronize ok !
> > no problem with the init of them !
> > My problem was ...on one of my tests ... I type reboot on server 1
> > primary !  Then ... server 2 get the proccess ... and become the
> > primary on DRBD !  But ... they become STANDALONE in the DRBD status
> > (cat /proc/drbd). Its ok because Server 1 is down !
> > So ... when i reboot Server 1 ... it loads the drbd on init again but dont
> join
> > this DRBD array that is PRIMARY on Server 2 !
> >
> > So then ... Server 2 stays as :
> > Standalone Prymary / Unknow
> >
> > and Server 1 stays :
> > WFconnection Secondary / Unknow
> >
> > From what i think ... Server 1 should back on the DRBD cluster as
> > Secondary as soon as it init again, right ?
> > but Server 2 stay as Standalone and dont let Server 1 back on the
> > array after the reboot.
> >
> > What can i do ? Is there anything ?
>
> have a look into syslog and heartbeat log files,
> and find the reason *why* it goes standalone;
> it will tell you.
>
> my first guess is, that on reboot, you first stop the network, and then
> stop heartbeat and/or drbd. this is *wrong*.
>
> on reboot:
>  * first stop heartbeat (which will release the drbd resource).
>    (drbd should now be "Secondary/Primary" on the rebooting node.)
>  * then stop drbd (which will unconfigure the drbd device).
>    (drbd should now be "Unconfigured" on the rebooting node.)
>  * only _then_ stop the network (since you no longer need it).
>
> otherwise, drbd generation counts will look as if there had been a
> split-brain situation (actually, there *has* been a split-brain
> situation as far as drbd is concerned).
> and drbd then refuses to connect, since it cannot automagically resolve
> this conflict.
>
> so get the order of actions on reboot right, and be happy.
>
> 	Lars Ellenberg

Hello Lars !

Good one ! Thanks !

I just add some lines on my reboot script (to stop heartbeat and drbd) ... and
then it works ok !

The server that stays online keeps the status WFconnection with Primary/Unknow.

Then when the master one backs from reboot it joins the array as secondary !

Thanks again !










More information about the drbd-user mailing list