1, modify the/etc/hosts
All service nodes execute:
10.5.25.37 glusterfs-1-5-25-37
10.5.25.38 glusterfs-2-5-25-38
2. Start the installation
All service nodes execute:
Apt-get Install Glusterfs-server-y
Service Glusterfs-server Start
3. Create a cluster node
37 performed on:
Gluster Peer probe glusterfs-2-5-25-38
Gluster Peer Status
38 performed on:
Gluster peer probe glusterfs-1-5-25-37 38 on execution
Gluster Peer Status
Delete/Add node command:
Gluster Peer Detach xxx
Gluster peer probe xxx
4. Create a disk partition, mount the directory
All service nodes execute:
Linux disk partition fdisk command in detail: http://www.cnblogs.com/wangkangluo1/archive/2012/06/08/2541161.html
Mkfs.ext4/dev/vdb
View results:
Blkid/dev/vdb
/dev/vdb:uuid= "Fa4a508f-ca6e-483a-a80a-ad76e9586e82" type= "Ext4"
Mount:
Mkdir-p/opt/gfs
Mount/dev/vdb/opt/gfs
Df-h Viewing mount conditions
Set up auto-mount on boot:
Vi/etc/fstab
/dev/vdb/opt/gfs EXT4 Default 0 1
Linux Fstab Automatic Mount partitioning tutorial: http://blog.sina.com.cn/s/blog_6ce9e88701014jgl.html
5. Create a distributed storage volume
Create Volume: http://blog.csdn.net/ptmagic/article/details/8782273
Http://zhidao.baidu.com/link?url=eqVAuyM7jnEZdu4vQ37UVS6a7E0LMt1gTrfSWAIu_v2HpcOfKsmY9Ws-H4Bi2MTS_tgwZs1V7YF0S3WnpcTsrK
Dynamic adjustment: http://blog.csdn.net/zonelan/article/details/8476281
Rationale: http://my.oschina.net/hncscwc/blog/225454
Gluster Volume Create gv_ansible replica 2 glusterfs-1-5-25-37:/opt/gfs/ansible glusterfs-2-5-25-38:/opt/gfs/ansible
View Volume Information:
Gluster Volume Info
To start a storage volume:
Gluster Volume start gv_ansible
Gluster Volume Info View as already started status
6, the Client
Apt-get Install Glusterfs-client-y
Mkdir-p/tmp/ansible
Mount.glusterfs 10.5.25.37:gv_ansible/tmp/ansible
Set boot auto mount, Vi/etc/fstab, append:
10.5.25.37:gv_ansible/tmp/ansible glusterfs Defaults,_netdev 0 0
OK, get it done!
Other reference materials: http://www.2cto.com/os/201210/160151.html
Distributed Storage System Glusterfs First experience: http://my.oschina.net/kisops/blog/151073
Glusterfs cluster system Installation and configuration method detailed (a): http://www.111cn.net/sys/linux/62609.htm
Recommended reading:http://www.linuxidc.com/Linux/2015-11/125106.htm
Https://www.digitalocean.com/community/tutorials/how-to-create-a-redundant-storage-pool-using-glusterfs-on-ubuntu-servers
Http://www.gluster.org/community/documentation/index.php/Setting_Up_Clients
Https://www.digitalocean.com/community/tutorials/how-to-create-a-redundant-storage-pool-using-glusterfs-on-ubuntu-servers
Construction Reference:http://www.cnblogs.com/lionelwu-qianqian/archive/2013/12/12/3470555.html
Umount:http://unix.stackexchange.com/questions/15024/umount-device-is-busy-why
"Cloud computing" Ubuntu14.04 build glusterfs Cluster