<html><body><div style="font-family: garamond,new york,times,serif; font-size: 12pt; color: #000000"><div><br></div><div><br></div><hr id="zwchr"><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><b>From: </b>"Shyam" &lt;srangana@redhat.com&gt;<br><b>To: </b>"Aravinda" &lt;avishwan@redhat.com&gt;, "Gluster Devel" &lt;gluster-devel@gluster.org&gt;<br><b>Sent: </b>Wednesday, September 2, 2015 8:09:55 PM<br><b>Subject: </b>Re: [Gluster-devel] Gluster Sharding and Geo-replication<br><div><br></div>On 09/02/2015 03:12 AM, Aravinda wrote:<br>&gt; Geo-replication and Sharding Team today discussed about the approach<br>&gt; to make Sharding aware Geo-replication. Details are as below<br>&gt;<br>&gt; Participants: Aravinda, Kotresh, Krutika, Rahul Hinduja, Vijay Bellur<br>&gt;<br>&gt; - Both Master and Slave Volumes should be Sharded Volumes with same<br>&gt; &nbsp; &nbsp;configurations.<br><div><br></div>If I am not mistaken, geo-rep supports replicating to a non-gluster <br>local FS at the slave end. Is this correct? If so, would this limitation <br>not make that problematic?<br><div><br></div>When you state *same configuration*, I assume you mean the sharding <br>configuration, not the volume graph, right?</blockquote><div>That is correct. The only requirement is for the slave to have shard translator (for, someone needs to present aggregated view of the file to the READers on the slave).<br></div><div>Also the shard-block-size needs to be kept same between master and slave. Rest of the configuration (like the number of subvols of DHT/AFR) can vary across master and slave.<br></div><div><br></div><div>-Krutika<br></div><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><br><div><br></div>&gt; - In Changelog record changes related to Sharded files also. Just like<br>&gt; &nbsp; &nbsp;any regular files.<br>&gt; - Sharding should allow Geo-rep to list/read/write Sharding internal<br>&gt; &nbsp; &nbsp;Xattrs if Client PID is gsyncd(-1)<br>&gt; - Sharding should allow read/write of Sharded files(that is in .shards<br>&gt; &nbsp; &nbsp;directory) if Client PID is GSYNCD<br>&gt; - Sharding should return actual file instead of returning the<br>&gt; &nbsp; &nbsp;aggregated content when the Main file is requested(Client PID<br>&gt; &nbsp; &nbsp;GSYNCD)<br>&gt;<br>&gt; For example, a file f1 is created with GFID G1.<br>&gt;<br>&gt; When the file grows it gets sharded into chunks(say 5 chunks).<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp;f1 &nbsp; G1<br>&gt; &nbsp; &nbsp; &nbsp;.shards/G1.1 &nbsp; G2<br>&gt; &nbsp; &nbsp; &nbsp;.shards/G1.2 &nbsp; G3<br>&gt; &nbsp; &nbsp; &nbsp;.shards/G1.3 &nbsp; G4<br>&gt; &nbsp; &nbsp; &nbsp;.shards/G1.4 &nbsp; G5<br>&gt;<br>&gt; In Changelog, this is recorded as 5 different files as below<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp;CREATE G1 f1<br>&gt; &nbsp; &nbsp; &nbsp;DATA G1<br>&gt; &nbsp; &nbsp; &nbsp;META G1<br>&gt; &nbsp; &nbsp; &nbsp;CREATE G2 PGS/G1.1<br>&gt; &nbsp; &nbsp; &nbsp;DATA G2<br>&gt; &nbsp; &nbsp; &nbsp;META G1<br>&gt; &nbsp; &nbsp; &nbsp;CREATE G3 PGS/G1.2<br>&gt; &nbsp; &nbsp; &nbsp;DATA G3<br>&gt; &nbsp; &nbsp; &nbsp;META G1<br>&gt; &nbsp; &nbsp; &nbsp;CREATE G4 PGS/G1.3<br>&gt; &nbsp; &nbsp; &nbsp;DATA G4<br>&gt; &nbsp; &nbsp; &nbsp;META G1<br>&gt; &nbsp; &nbsp; &nbsp;CREATE G5 PGS/G1.4<br>&gt; &nbsp; &nbsp; &nbsp;DATA G5<br>&gt; &nbsp; &nbsp; &nbsp;META G1<br>&gt;<br>&gt; Where PGS is GFID of .shards directory.<br>&gt;<br>&gt; Geo-rep will create these files independently in Slave Volume and<br>&gt; syncs Xattrs of G1. Data can be read only when all the chunks are<br>&gt; synced to Slave Volume. Data can be read partially if main/first file<br>&gt; and some of the chunks synced to Slave.<br>&gt;<br>&gt; Please add if I missed anything. C &amp; S Welcome.<br>&gt;<br>&gt; regards<br>&gt; Aravinda<br>&gt;<br>&gt; On 08/11/2015 04:36 PM, Aravinda wrote:<br>&gt;&gt; Hi,<br>&gt;&gt;<br>&gt;&gt; We are thinking different approaches to add support in Geo-replication<br>&gt;&gt; for Sharded Gluster Volumes[1]<br>&gt;&gt;<br>&gt;&gt; *Approach 1: Geo-rep: Sync Full file*<br>&gt;&gt; &nbsp; &nbsp;- In Changelog only record main file details in the same brick<br>&gt;&gt; where it is created<br>&gt;&gt; &nbsp; &nbsp;- Record as DATA in Changelog whenever any addition/changes to the<br>&gt;&gt; sharded file<br>&gt;&gt; &nbsp; &nbsp;- Geo-rep rsync will do checksum as a full file from mount and<br>&gt;&gt; syncs as new file<br>&gt;&gt; &nbsp; &nbsp;- Slave side sharding is managed by Slave Volume<br>&gt;&gt; *Approach 2: Geo-rep: Sync sharded file separately*<br>&gt;&gt; &nbsp; &nbsp;- Geo-rep rsync will do checksum for sharded files only<br>&gt;&gt; &nbsp; &nbsp;- Geo-rep syncs each sharded files independently as new files<br>&gt;&gt; &nbsp; &nbsp;- [UNKNOWN] Sync internal xattrs(file size and block count) in the<br>&gt;&gt; main sharded file to Slave Volume to maintain the same state as in Master.<br>&gt;&gt; &nbsp; &nbsp;- Sharding translator to allow file creation under .shards dir for<br>&gt;&gt; gsyncd. that is Parent GFID is .shards directory<br>&gt;&gt; &nbsp; &nbsp;- If sharded files are modified during Geo-rep run may end up stale<br>&gt;&gt; data in Slave.<br>&gt;&gt; &nbsp; &nbsp;- Files on Slave Volume may not be readable unless all sharded<br>&gt;&gt; files sync to Slave(Each bricks in Master independently sync files to<br>&gt;&gt; slave)<br>&gt;&gt;<br>&gt;&gt; First approach looks more clean, but we have to analize the Rsync<br>&gt;&gt; checksum performance on big files(Sharded in backend, accessed as one<br>&gt;&gt; big file from rsync)<br>&gt;&gt;<br>&gt;&gt; Let us know your thoughts. Thanks<br>&gt;&gt;<br>&gt;&gt; Ref:<br>&gt;&gt; [1]<br>&gt;&gt; http://www.gluster.org/community/documentation/index.php/Features/sharding-xlator<br>&gt;&gt; --<br>&gt;&gt; regards<br>&gt;&gt; Aravinda<br>&gt;&gt;<br>&gt;&gt;<br>&gt;&gt; _______________________________________________<br>&gt;&gt; Gluster-devel mailing list<br>&gt;&gt; Gluster-devel@gluster.org<br>&gt;&gt; http://www.gluster.org/mailman/listinfo/gluster-devel<br>&gt;<br>&gt;<br>&gt;<br>&gt; _______________________________________________<br>&gt; Gluster-devel mailing list<br>&gt; Gluster-devel@gluster.org<br>&gt; http://www.gluster.org/mailman/listinfo/gluster-devel<br>&gt;<br>_______________________________________________<br>Gluster-devel mailing list<br>Gluster-devel@gluster.org<br>http://www.gluster.org/mailman/listinfo/gluster-devel<br></blockquote><div><br></div></div></body></html>