glusterFS搭建: | 第一次创建复制卷的命令:replica 2 双副本机制,后面跟每个节点的brick
gluster volume create myvolume replica 2 transport tcp 10.xx.xx.xx:/glusterfs/data xx.xx.xx.xx:/glusterfs/data |
扩容命令如下: | 在任意一台glusterFS节点上面操作,添加新增的节点
#gluster peer probe 192.168.1.178 #gluster peer probe 192.168.1.179 #gluster peer probe 192.168.1.180 #gluster peer probe 192.168.1.181 #gluster peer probe 192.168.1.182 #gluster peer probe 192.168.1.183 #gluster peer probe 192.168.1.184 #gluster peer probe 192.168.1.185 #gluster volume add-brick myvolume 192.168.1.178:/glusterfs/data 192.168.1.179:/glusterfs/data 192.168.1.180:/glusterfs/data 192.168.1.181:/glusterfs/data 192.168.1.182:/glusterfs/data 192.168.1.183:/glusterfs/data 192.168.1.184:/glusterfs/data 192.168.1.185:/glusterfs/data
#gluster volume rebalance myvolume start 启动均衡设置 #gluster volume rebalance myvolume status 查看均衡状态
查看卷的状态,以前是两台节点的时候是复制卷,目前是10个节点的时候是分布式复制卷,也就是第一个数据file1写入node1复制到node2,第二个数据file2写入到node3复制到node4,以此类推;
# gluster volume info myvolume
Volume Name: myvolume Type: Distributed-Replicate Volume ID: 56d4ddf3-b38a-4f6c-8c11-dcb2dc5dedba Status: Started Number of Bricks: 5 x 2 = 10 Transport-type: tcp Bricks: Brick1: 192.168.1.174:/glusterfs/data Brick2: 192.168.1.175:/glusterfs/data Brick3: 192.168.1.178:/glusterfs/data Brick4: 192.168.1.179:/glusterfs/data Brick5: 192.168.1.180:/glusterfs/data Brick6: 192.168.1.181:/glusterfs/data Brick7: 192.168.1.182:/glusterfs/data Brick8: 192.168.1.183:/glusterfs/data Brick9: 192.168.1.184:/glusterfs/data Brick10: 192.168.1.185:/glusterfs/data |
|
|
glusterFS 扩容案例
最新推荐文章于 2023-09-27 00:00:00 发布