<div dir="ltr">Adding more people to get a consensus about this. <br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jun 20, 2017 at 1:49 PM, Aravinda <span dir="ltr"><<a href="mailto:avishwan@redhat.com" target="_blank">avishwan@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
regards<br>
Aravinda VK<div><div class="h5"><br>
<br>
On 06/20/2017 01:26 PM, Xavier Hernandez wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Pranith,<br>
<br>
adding gluster-devel, Kotresh and Aravinda,<br>
<br>
On 20/06/17 09:45, Pranith Kumar Karampuri wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
On Tue, Jun 20, 2017 at 1:12 PM, Xavier Hernandez <<a href="mailto:xhernandez@datalab.es" target="_blank">xhernandez@datalab.es</a><br>
<mailto:<a href="mailto:xhernandez@datalab.es" target="_blank">xhernandez@datalab.es</a>><wbr>> wrote:<br>
<br>
On 20/06/17 09:31, Pranith Kumar Karampuri wrote:<br>
<br>
The way geo-replication works is:<br>
On each machine, it does getxattr of node-uuid and check if its<br>
own uuid<br>
is present in the list. If it is present then it will consider<br>
it active<br>
otherwise it will be considered passive. With this change we are<br>
giving<br>
all uuids instead of first-up subvolume. So all machines think<br>
they are<br>
ACTIVE which is bad apparently. So that is the reason. Even I<br>
felt bad<br>
that we are doing this change.<br>
<br>
<br>
And what about changing the content of node-uuid to include some<br>
sort of hierarchy ?<br>
<br>
for example:<br>
<br>
a single brick:<br>
<br>
NODE(<guid>)<br>
<br>
AFR/EC:<br>
<br>
AFR[2](NODE(<guid>), NODE(<guid>))<br>
EC[3,1](NODE(<guid>), NODE(<guid>), NODE(<guid>))<br>
<br>
DHT:<br>
<br>
DHT[2](AFR[2](NODE(<guid>), NODE(<guid>)), AFR[2](NODE(<guid>),<br>
NODE(<guid>)))<br>
<br>
This gives a lot of information that can be used to take the<br>
appropriate decisions.<br>
<br>
<br>
I guess that is not backward compatible. Shall I CC gluster-devel and<br>
Kotresh/Aravinda?<br>
</blockquote>
<br>
Is the change we did backward compatible ? if we only require the first field to be a GUID to support backward compatibility, we can use something like this:<br>
</blockquote></div></div>
No. But the necessary change can be made to Geo-rep code as well if format is changed, Since all these are built/shipped together.<br>
<br>
Geo-rep uses node-id as follows,<br>
<br>
list = listxattr(node-uuid)<br>
active_node_uuids = list.split(SPACE)<br>
active_node_flag = True if self.node_id exists in active_node_uuids else False<div class="HOEnZb"><div class="h5"><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Bricks:<br>
<br>
<guid><br>
<br>
AFR/EC:<br>
<guid>(<guid>, <guid>)<br>
<br>
DHT:<br>
<guid>(<guid>(<guid>, ...), <guid>(<guid>, ...))<br>
<br>
In this case, AFR and EC would return the same <guid> they returned before the patch, but between '(' and ')' they put the full list of guid's of all nodes. The first <guid> can be used by geo-replication. The list after the first <guid> can be used for rebalance.<br>
<br>
Not sure if there's any user of node-uuid above DHT.<br>
<br>
Xavi<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<br>
<br>
Xavi<br>
<br>
<br>
On Tue, Jun 20, 2017 at 12:46 PM, Xavier Hernandez<br>
<<a href="mailto:xhernandez@datalab.es" target="_blank">xhernandez@datalab.es</a> <mailto:<a href="mailto:xhernandez@datalab.es" target="_blank">xhernandez@datalab.es</a>><br>
<mailto:<a href="mailto:xhernandez@datalab.es" target="_blank">xhernandez@datalab.es</a> <mailto:<a href="mailto:xhernandez@datalab.es" target="_blank">xhernandez@datalab.es</a>><wbr>>><br>
wrote:<br>
<br>
Hi Pranith,<br>
<br>
On 20/06/17 07:53, Pranith Kumar Karampuri wrote:<br>
<br>
hi Xavi,<br>
We all made the mistake of not sending about changing<br>
behavior of<br>
node-uuid xattr so that rebalance can use multiple nodes<br>
for doing<br>
rebalance. Because of this on geo-rep all the workers<br>
are becoming<br>
active instead of one per EC/AFR subvolume. So we are<br>
frantically trying<br>
to restore the functionality of node-uuid and introduce<br>
a new<br>
xattr for<br>
the new behavior. Sunil will be sending out a patch for<br>
this.<br>
<br>
<br>
Wouldn't it be better to change geo-rep behavior to use the<br>
new data<br>
? I think it's better as it's now, since it gives more<br>
information<br>
to upper layers so that they can take more accurate decisions.<br>
<br>
Xavi<br>
<br>
<br>
--<br>
Pranith<br>
<br>
<br>
<br>
<br>
<br>
--<br>
Pranith<br>
<br>
<br>
<br>
<br>
<br>
-- <br>
Pranith<br>
</blockquote>
<br>
</blockquote>
<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">Pranith<br></div></div>
</div>