ansible.role.gluster/README.md

28 lines
1.0 KiB
Markdown
Raw Permalink Normal View History

2019-04-26 13:43:48 +08:00
# playbook for installing gluster 6.1.
2019-04-26 13:48:22 +08:00
This role installs the necessary packages for gluster. It does not create any volume. An example is shown below on how to create a 2 replica volume with 1 arbiter.
2019-04-26 13:43:48 +08:00
## Nodes
2019-05-03 15:14:04 +08:00
This role sets up 3 servers. All have a secondary data disk attached on /dev/nvme1n1. They will be formatted in ext4 and mounted under /.gluster/brick1. ext4 is used for better performance with small files.
2019-04-26 13:43:48 +08:00
## Create gluster: 2 replica and 1 arbiter
2019-05-03 15:14:04 +08:00
Run these on one of the gluster nodes:
2019-04-26 13:43:48 +08:00
```
gluster peer probe gluster-s1
gluster peer probe gluster-s2
gluster vol create gv0 replica 2 arbiter 1 gluster-s1:/.gluster/brick1 gluster-s2:/.gluster/brick1 gluster-a1:/.gluster/brick1
gluster vol start gv0
gluster vol set gv0 performance.cache-size 256MB
gluster vol set gv0 nfs.disable On
gluster vol set gv0 server.event-threads 12
gluster vol set gv0 client.event-threads 4
```
2019-05-02 23:00:46 +08:00
### System tuning
2019-05-03 15:09:51 +08:00
Playbook changes tuned profile for gluster
2019-05-02 23:00:46 +08:00
```
2019-05-03 15:09:51 +08:00
# tuned-adm profile throughput-performance
2019-05-02 23:00:46 +08:00
# tuned-adm active
```