Unify over AFR

From GlusterDocumentation

Jump to: navigation, search

Server spec file

volume brick
 type storage/posix 
 option directory /home/export/
end-volume

volume brick-ns
 type storage/posix
 option directory /home/export-ns/
end-volume

### Add network serving capability to above brick.
volume server
 type protocol/server
 option transport-type tcp/server     # For TCP/IP transport
 subvolumes brick brick-ns
 option auth.ip.brick.allow 192.168.1.* # Allow access to "brick" volume
 option auth.ip.brick-ns.allow 192.168.1.* # Allow access to "brick-ns" volume
end-volume

Client spec file

volume brick1
 type protocol/client
 option transport-type tcp/client     # for TCP/IP transport
 option remote-host 192.168.1.1      # IP address of the remote brick
 option remote-subvolume brick        # name of the remote volume
end-volume

volume brick2
 type protocol/client
 option transport-type tcp/client
 option remote-host 192.168.1.2
 option remote-subvolume brick
end-volume

volume brick3
 type protocol/client
 option transport-type tcp/client
 option remote-host 192.168.1.3
 option remote-subvolume brick
end-volume

volume brick4
 type protocol/client
 option transport-type tcp/client
 option remote-host 192.168.1.4
 option remote-subvolume brick
end-volume

volume brick5
 type protocol/client
 option transport-type tcp/client 
 option remote-host 192.168.1.5
 option remote-subvolume brick
end-volume

volume brick6
 type protocol/client
 option transport-type tcp/client
 option remote-host 192.168.1.6
 option remote-subvolume brick
end-volume

volume brick-ns1
 type protocol/client
 option transport-type tcp/client
 option remote-host 192.168.1.1
 option remote-subvolume brick-ns  # Note the different remote volume name.
end-volume

volume brick-ns2
 type protocol/client
 option transport-type tcp/client
 option remote-host 192.168.1.2
 option remote-subvolume brick-ns  # Note the different remote volume name.
end-volume

volume afr1
 type cluster/afr
 subvolumes brick1 brick4 
end-volume

volume afr2
 type cluster/afr
 subvolumes brick2 brick5
end-volume

volume afr3
 type cluster/afr
 subvolumes brick3 brick6
end-volume

volume afr-ns
 type cluster/afr
 subvolumes brick-ns1 brick-ns2
end-volume

volume unify
 type cluster/unify
 option namespace afr-ns
 option scheduler rr
 subvolumes afr1 afr2 afr3
end-volume
Personal tools