关键词:
第一:安装依赖包:
yum install libibverbs librdmacm xfsprogs nfs-utils rpcbind libaio liblvm2app lvm2-devel libevent-devel nfs-utils-lib-devel tcl-devel libsysfs-devel userspace-rcu atop iozone fio iperf
安装gluserfs server 和 client
yum install glusterfs glusterfs-server glusterfs-fuse
# yum install glusterfs-3.7.9-12 glusterfs-server-3.7.8-1.el7.x86_64
yum -y install glusterfs glusterfs-client
8.组建集群
/etc/init.d/glusterd start
chkconfig glusterd on
登陆服务器server1,执行命令
[root@server1 yum.repos.d]# gluster peer probe server2
[root@server1 yum.repos.d]# gluster peer probe server3
使用 gluster peer status 查看状态
9.创建卷
1.确定创建卷的类型
2.去创建卷的brick列表
3.确定创建卷的网络类型(TCP/RDMA)
4.gluster volume create 创建复制卷,至少2台主机
卷里使用2台主机
gluster volume create testvol replica 3 server1:/brick1/images server2:/brick1/images
#分布式复制glusterfs卷,至少4台主机
#gluster volume create fengvol replica 2 transport tcp judge1:/data/feng judge2:/data/feng graph1:/data/feng graph2:/data/feng force
查看volume 卷信息
为硬盘访问设置权限:
Gluster volume set testVol auth.allow 172.16.1.*
启动创建的卷
gluster volume start testVol
查看卷的扩展属性
getfattr -d -m . -e hex /brick1/images
客户端挂载
mount -t glusterfs glusterfs1:/testvol /data
cat /etc/fstab
glusterfs1:/testvol /data glusterfs defaults 0 0
# 设置 cache 大小, 默认32MB
$ gluster volume set testvol performance.cache-size 4GB
# 设置 io 线程, 太大会导致进程崩溃
$ gluster volume set testvol performance.io-thread-count 16
# 设置 网络检测时间, 默认42s
$ gluster volume set testvol network.ping-timeout 10
# 设置 写缓冲区的大小, 默认1M
$ gluster volume set testvol performance.write-behind-window-size 1024MB
查看卷
Gluster volume info
删除卷
gluster volume stop testvol
gluster volume delete testvol
将机器移出集群
gluster peer detach 172.28.26.102
只允许172.28.0.0的网络访问glusterfs
gluster volume set testvol auth.allow 172.28.26.*
加入新的机器并添加到卷里(由于副本数设置为2,至少要添加2(4、6、8..)台机器)
gluster peer probe 172.28.26.105
gluster peer probe 172.28.26.106
gluster volume add-brick testvol 172.28.26.105:/data/gluster 172.28.26.106:/data/gluster
收缩卷
# 收缩卷前gluster需要先移动数据到其他位置
gluster volume remove-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.102:/data/gluster/testvol start
# 查看迁移状态
gluster volume remove-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.102:/data/gluster/testvol status
# 迁移完成后提交
gluster volume remove-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.102:/data/gluster/testvol commit
迁移卷
# 将172.28.26.101的数据迁移到,先将172.28.26.107加入集群
gluster peer probe 172.28.26.107
gluster volume replace-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.107:/data/gluster/testvol start
# 查看迁移状态gluster volume replace-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.107:/data/gluster/testvol status
# 数据迁移完毕后提交gluster volume replace-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.107:/data/gluster/testvol commit
# 如果机器172.28.26.101出现故障已经不能运行,执行强制提交然后要求gluster马上执行一次同步
gluster volume replace-brick testvol 172.28.26.101:/data/gluster/testvol 172.28.26.102:/data/gluster/testvol commit -force
gluster volume heal testvol s full
移除集群 gluster peer detach server3
56.glusterfs分布式文件系统
GlusterFS分布式文件系统GlusterFS是一个开源的分布式文件系统,软件的结构设计良好,易于扩展和配置,通过各个模块的灵活搭配得到针对性的解决方案。可解决一下问题:网络存储,联合存储,冗余备份,大文件的负载均衡。可... 查看详情
分布式文件系统---glusterfs介绍
...terFS是Scale-Out存储解决方案Gluster的核心,它是一个开源的分布式文件系统,具有强大的横向扩展能力,通过扩展能够支持数PB存储容量和处理数千客户端。GlusterFS借助TCP/IP或InfiniBandRDMA网络将物理分布的存储资源聚集在一起,使... 查看详情
分布式文件系统-glusterfs
1.1分布式文件系统1.1.1什么是分布式文件系统 相对于本机端的文件系统而言,分布式文件系统(英语:Distributedfilesystem, DFS),或是网络文件系统(英语:NetworkFileSystem),是一种允许文件通过网络在多台主机上分享的文... 查看详情
glusterfs分布式文件系统
glusterfs第1章什么是分布式文件系统?相对于本极端的文件系统而言,分布式文件系统DFS,伙食网络文件系统NFS,是一种允许文件通过网络在多台主机上分享的文件系统你那个,可以让多机器上的多用户分享指定问加你和存储空间在这样... 查看详情
分布式文件系统--------glusterfs最佳实战
1.背景 GlusterFS是一个开源的分布式文件系统,具有强大的横向扩展能力,通过扩展能够支持数PB存储容量和处理数千客户端。GlusterFS借助TCP/IP或InfiniBandRDMA(一种支持多并发链接的“转换线缆”技术)网络将物理分布的... 查看详情
分布式文件系统--glusterfs(代码片段)
文章目录一、分布式文件系统1.文件系统1.1组成1.2作用1.3挂载使用2.分布式文件系统--GFS2.1组成2.2专业术语2.3模块化堆栈式架构2.4工作流程2.5基本卷与复合卷二、部署GlusterFS群集1准备环境2配置/etc/hosts文件3安装GlusterFS并启动4时间... 查看详情
glusterfs分布式文件系统(代码片段)
GlusterFS分布式文件系统,用于存储、管理磁盘文件文件系统(FS)文件系统组成1、文件系统接口2、对对像管理的软件集合3、对象及属性文件系统作用从系统角度来看,文件系统是对文件存储设备的空间进行组织和分配... 查看详情
脑壳有点疼。。glusterfs分布式文件系统!(更新中)
GlusterFS分布式文件系统一.文件系统简介1.组成2.作用3.挂载使用二.GlusterFS分布式文件系统1.GFS是由三部分组成(组件)2.GFS特点3.GFS专业术语4.GFS模块化堆栈式架构5.工作流程6.基本卷和复合卷三.部署GFS集群1.实验准备一.文... 查看详情
分布式文件系统---glusterfs安装配置
一、环境规划GlusterFS服务端:10.100.0.41/10.100.0.44GlusterFS客户端:10.100.0.43二、所需软件包glusterfs-server-3.4.2-1.el6.x86_64glusterfs-3.4.2-1.el6.x86_64三、安装 3.1、服务端安装#wget-P/etc/yum.repos.dhttp://dow 查看详情
glusterfs分布式文件系统概述(代码片段)
...GlusterFS的工作流程2、弹性HASH算法三、GlusterFS的卷类型1、分布式卷2、条带卷3、复制卷4、分布式条带卷5、分布式复制卷一、GlusterFS概述GlusterFS是一个开源的分布式文件系统,同时也是Scale-Out存储解决方案Gluster的核心,在存储数... 查看详情
glusterfs分布式文件系统
分布式系统要做的任务就是把多台机器有机的组合、连接起来,让其协同完成一件任务,可以是计算任务,也可以是存储任务。如果一定要给近些年的分布式系统研究做一个分类的话,大概可以包括三大部分:1.分布式存储系统2... 查看详情
glusterfs分布式文件系统部署
...terFS是Scale-Out存储解决方案Gluster的核心,它是一个开源的分布式文件系统,具有强大的横向扩展能力,通过扩展能够支持数PB存储容量和处理数千客户端。GlusterFS借助TCP/IP或InfiniBandRDMA网络将物理分布的存储资源聚集在一起,使... 查看详情
glusterfs分布式文件系统
第一:安装依赖包:yuminstalllibibverbslibrdmacmxfsprogsnfs-utilsrpcbindlibaioliblvm2app lvm2-devel libevent-devel nfs-utils-lib-develtcl-devellibsysfs-devel userspace-rcu atop ioz 查看详情
详解gfs分布式文件系统(条带卷/复制卷/分布式条带卷/分布式复制卷)(代码片段)
GFS分布式文件系统一.GlusterFS概述1.GlusterFS简介2.GlusterFS特点3.GlusterFS术语4.模块化堆栈式架构5.GlusterFS工作流程6.弹性HASH算法7.GlusterFs的卷类型二.部署GlusterFs群集三.客户端部署与测试测试总结补充:一.GlusterFS概述1.GlusterFS简介... 查看详情
glusterfs-----文件分布系统+集群部署(代码片段)
一、Gluster概述1.1、gluster简介Glusterfs是一个开源的分布式文件系统,是Scale存储的核心,能够处理千数量级的客户端.在传统的解决方案中Glusterfs能够灵活的结合物理的,虚拟的和云资源去体现高可用和企业级的性能存储.Glusterfs通过TCP... 查看详情
glusterfs-----文件分布系统+集群部署(代码片段)
一、Gluster概述1.1、gluster简介Glusterfs是一个开源的分布式文件系统,是Scale存储的核心,能够处理千数量级的客户端.在传统的解决方案中Glusterfs能够灵活的结合物理的,虚拟的和云资源去体现高可用和企业级的性能存储.Glusterfs通过TCP... 查看详情
gfs分布式文件系统(代码片段)
目录一.GlusterFS概述1.GlusterFS简介2.GlusterFS特点3.GlusterFS术语4.模块化堆栈式架构5.GlusterFS的工作流程6.弹性HASH算法7.GlusterFs的卷类型二.部署GlusterFS群集1.准备环境(所有node节点上操作)①添加硬盘,关闭防火墙,修改所有node节... 查看详情
gfs分布式文件系统(代码片段)
...GlusterFS介绍1.1GlusterFS概念1.2GlusterFS特点1.3GlusterFS术语前言分布式文件系统种类有:CEPH分布式文件系统(用的多)GFS(GlusterFS)分布式文件系统M 查看详情