server side replication in gluster with avra sengupta

10

Click here to load reader

Upload: glusterorg

Post on 08-Jan-2017

157 views

Category:

Technology


2 download

TRANSCRIPT

Page 1: Server side replication in Gluster with Avra Sengupta

Gluster Replication

Avra Sengupta([email protected])

7th October, 2016Gluster Developer Summit - 2016

Reach us [email protected]

Page 2: Server side replication in Gluster with Avra Sengupta

Agenda

● Client Side Replication

● Client Side Replication - Challenges

● Server Side Replication

● Server Side Replication - Advantages

● Simpler Client

● Journals and Xattrs

Page 3: Server side replication in Gluster with Avra Sengupta

Client Side Replication

Node 1 Node 2 Node 3

Client 1● Lock Phase

Client to Server Network Calls :

Server to Client Network Calls :

0

0

3

3

● Pre-Op Phase

6

Xattr update Xattr update Xattr update

6

● Op Phase

9

9

● Post-Op Phase

12

12

● Unlock Phase

15

15

Total Network Calls : 30

Page 4: Server side replication in Gluster with Avra Sengupta

Client Side Replication - Challenges

Node 1 Node 2 Node 3

Client 1 Client 2 Client 3

Node 1 Attributes:brick-1=0x000000000000000000000000brick-2=0x000000010000000000000000

Node 2 Attributes:brick-0=0x000000000000000000000000brick-2=0x000000010000000000000000

Node 3 Attributes:brick-0=0x000000000000000000000000brick-1=0x000000000000000000000000

Node 1 Attributes:brick-1=0x000000010000000000000000brick-2=0x000000010000000000000000

Node 3 Attributes:brick-0=0x000000000000000000000000brick-1=0x000000010000000000000000

Node 2 Attributes:brick-0=0x000000010000000000000000brick-2=0x000000010000000000000000

Node 3 Attributes:brick-0=0x000000010000000000000000brick-1=0x000000010000000000000000

Page 5: Server side replication in Gluster with Avra Sengupta

Server Side Replication

Node 1 Node 2 Node 3

Client 1

● Leader driven: Client sends the fop to the leader

● Leader fans it out to the followers

Client to Server Network Calls :

Server to Client Network Calls :

0

0

1Server to Server Network Calls : 02

● Followers perform the fop and send ack to the leader

4

● Leader then performs the fop

● Leader sends acknowledgement back to the client

1

Total Network Calls : 6

Page 6: Server side replication in Gluster with Avra Sengupta

Server Side Replication - Advantages

● Avoids Network Split Brain through leader election

● As low as 6 network call as opposed to 30 network calls in client side replication

● Leveraging server to server bandwidth for replication

● Simplifies coordination as no locking is needed between clients.

Page 7: Server side replication in Gluster with Avra Sengupta

Simpler Client

Guess Which Brick Is Leader

Send I/O

EREMOTENO

Try Sending I/O To Next Brick

YES

Page 8: Server side replication in Gluster with Avra Sengupta

Server Graphvolume test_vol-barrier

type features/barriersubvolumes test_vol-marker

end-volume

volume test_vol-client-0type protocol/clientoption remote-subvolume /brick/brick-dirs/brickoption remote-host 192.168.122.106

end-volume

volume test_vol-client-1type protocol/clientoption remote-subvolume /brick/brick-dirs2/brickoption remote-host 192.168.122.106

end-volume

volume test_vol-jbrtype experimental/jbroption quorum-percent 100option leader yessubvolumes test_vol-barrier test_vol-client-0 test_vol-client-1

end-volume

volume test_vol-quotatype features/quotasubvolumes test_vol-jbr

end-volume

Node 1 Node 2 Node 3

Server

Page 9: Server side replication in Gluster with Avra Sengupta

Journals and Xattrs

● JBR, AFR, and EC plan to utilise server side replication in Gluster 4.0

● JBR and AFR, would then differ in how they provide data consistency

○ JBR would be using full data journaling

○ Afr would be using xattrs

● And in case hell freezes over, we might just have only one single replication model, using any one of

the above methods.

Page 10: Server side replication in Gluster with Avra Sengupta

Q&A