snow chuai汇总、整理、撰写---2020/07/24
+----------------------+ | +----------------------+ | [GlusterFS Server#1] |192.168.10.11 | 192.168.10.12| [GlusterFS Server#2] | | node1.1000cc.net +--------------+--------------+ node2.1000cc.net | | | | | | +----------------------+ | +----------------------+ | +----------------------+ | +----------------------+ | [GlusterFS Server#3] |192.168.10.13 | 192.168.10.14| [GlusterFS Server#4] | | node3.1000cc.net +--------------+--------------+ node4.1000cc.net | | | | | | +----------------------+ | +----------------------+ | +----------------------+ | +----------------------+ | [GlusterFS Server#5] |192.168.10.15 | 192.168.10.16| [GlusterFS Server#6] | | node5.1000cc.net +--------------+--------------+ node6.1000cc.net | | | | | | +----------------------+ | +----------------------+ | |192.168.10.17 +-----------+---------+ | [GlusterFS Client] | | node7.1000cc.net | | | +---------------------+
1) 安装GFS Server到所有节点 [root@node1 ~]# yum install centos-release-gluster7 -y
[root@node1 ~]# sed -i -e "s/enabled=1/enabled=0/g" /etc/yum.repos.d/CentOS-Gluster-7.repo [root@node1 ~]# yum --enablerepo=centos-gluster7 install glusterfs-server -y
[root@node1 ~]# systemctl enable --now glusterd [root@node1 ~]# gluster --version glusterfs 7.4 Repository revision: git://git.gluster.org/glusterfs.git Copyright (c) 2006-2016 Red Hat, Inc. <https://www.gluster.org/> GlusterFS comes with ABSOLUTELY NO WARRANTY. It is licensed to you under your choice of the GNU Lesser General Public License, version 3 or any later version (LGPLv3 or later), or the GNU General Public License, version 2 (GPLv2), in all cases as published by the Free Software Foundation.
2) 防火墙配置 [root@node1 ~]# firewall-cmd --add-service=glusterfs --permanent success [root@node1 ~]# firewall-cmd --reload success
1) 在所有节点上建立dist vol目录 [root@node1 ~]# mkdir -p /gfs/dist |
1) 安装GFS源及相关软件 [root@node7 ~]# yum install centos-release-gluster7 -y [root@node7 ~]# sed -i -e "s/enabled=1/enabled=0/g" /etc/yum.repos.d/CentOS-Gluster-7.repo [root@node7 ~]# yum --enablerepo=centos-gluster7 install glusterfs glusterfs-fuse -y |
1) 启用quota机制 [root@node1 ~]# gluster volume quota dist_vol enable volume quota : success |
1) 请先完成Distributed配置 |
1) 安装Gluster工具并启动Gluster服务 [root@node4 ~]# yum install centos-release-gluster7 -y |
1) 查看卷信息 [root@node1 ~]# gluster volume info Volume Name: dist_vol Type: Distribute Volume ID: 89287b49-1c7c-4331-bbe0-f5182d807085 Status: Started Snapshot Count: 0 Number of Bricks: 4 Transport-type: tcp Bricks: Brick1: node1:/gfs/dist Brick2: node2:/gfs/dist Brick3: node3:/gfs/dist Brick4: node4:/gfs/dist Options Reconfigured: transport.address-family: inet storage.fips-mode-rchecksum: on nfs.disable: on |
1) 停止Vol [root@node1 ~]# gluster volume stop dist_vol Stopping volume will make its data inaccessible. Do you want to continue? (y/n) y volume stop: dist_vol: success |
1) 在所有的节点上创建gfs所需的目录 [root@node1 ~]# mkdir -p /gfs/replica |
0) 配置6台节点均安装完成GFS工具 |
1) 于所有节点建立存储目录 [root@node1 ~]# mkdir -p /gfs/disp |