<div dir="ltr"><div>Hi Digimer,</div><div><br></div><div>Thanks for your reply! </div><div><br></div><div>Yes, I understand fencing can prevent <span style="font-size:12.6666669845581px">split-brains. But in my case it maybe not sufficient. Let me clarify my use case. Basically, you can get the architecture from <a href="http://ibin.co/2YoKo5VOmRYn">http://ibin.co/2YoKo5VOmRYn</a> The app on each client server will do I/O via block interface directly instead using a cluster file system. Every client server need write access to all drdb volumes to build a VG group. But the application can guarantee that no two servers write to the same data area at the same time because it just writes to the data belonging to itself even when spli-brain happens. So merging data I mentioned before means just pull all newest data from different volumes together. </span></div><div><span style="font-size:12.6666669845581px"><br></span></div><div><span style="font-size:12.6666669845581px">For the suggestion of fencing, I think it still can cause somehow out-of-sync because the fencing is invoked by cluster management software, but in data plane the I/O could be done before the fencing happens.</span></div><div><span style="font-size:12.6666669845581px"><br></span></div><div><span style="font-size:12.6666669845581px"><br></span></div><div><span style="font-size:12.6666669845581px"><br></span></div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div><div><span style="font-size:12.6666669845581px"><br></span></div><div><span style="font-size:12.6666669845581px"><br></span></div><div><span style="font-size:12.6666669845581px">my understanding is that fencing is invoked by the cluster management software asynchronously. </span></div><div><br></div><div><br></div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 2, 2016 at 1:07 AM, Digimer <span dir="ltr"><<a href="mailto:lists@alteeve.ca" target="_blank">lists@alteeve.ca</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On 01/03/16 09:43 AM, Mark Wu wrote:<br>
> Hi guys,<br>
><br>
> According to<br>
> <a href="http://drbd.linbit.com/users-guide-9.0/s-dual-primary-mode.html" rel="noreferrer" target="_blank">http://drbd.linbit.com/users-guide-9.0/s-dual-primary-mode.html</a>,<br>
> DRBD-9.1 will support multiple primaries. I am wondering if it can<br>
> also enhance the auto reovery from split brain. It seems that currently<br>
> we don't have a good solution of recoverying from split brain without<br>
> data loss when dual primary is configured. I think it will be good to<br>
> have a policy to merge all up-to-date data.<br>
><br>
> I am considering to build a storage pool by aggregating remote drbd<br>
> volumes into a VG and then any client can write to LV created in the VG.<br>
> This solution can remove the limitation of single host's storage<br>
> capacity when thin provisioning is enabled.<br>
> If thin-provisioning is enabled with drbdmanage, the new-added storage<br>
> servers can't help the node which runs out of storage space.<br>
><br>
><br>
> That's why I care about the case of multiple primaries. Thanks for any<br>
> feedback!<br>
<br>
</div></div>Fencing prevents split-brains in the first place, use it.<br>
<br>
As for auto-recovery in dual-primary;<br>
<br>
Consider that DRBD is not aware of data structures. So there is no safe<br>
way to say how to merge data back. It would have to be done at the<br>
FS-layer. If you simply said "well, sync over the node with older data",<br>
or "sync over the node with fewer changes", consider this scenario; Your<br>
accounting data is updated on one node, then sometime later, an ISO<br>
image is written to the other node. I am pretty sure that the older,<br>
smaller changes are a lot more valuable.<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Digimer<br>
Papers and Projects: <a href="https://alteeve.ca/w/" rel="noreferrer" target="_blank">https://alteeve.ca/w/</a><br>
What if the cure for cancer is trapped in the mind of a person without<br>
access to education?<br>
</font></span></blockquote></div><br></div>