Chapter 4. Configure performance improvements
Some deployments benefit from additional configuration to achieve optimal performance. This section covers recommended additional configuration for certain deployments.
4.1. Improving volume performance by changing shard size Copy linkLink copied to clipboard!
The default value of the shard-block-size
parameter changed from 4MB
to 64MB
between Red Hat Hyperconverged Infrastructure for Virtualization version 1.0 and 1.1. This means that all new volumes are created with a shard-block-size
value of 64MB. However, existing volumes retain the original shard-block-size
value of 4MB.
There is no safe way to modify the shard-block-size
value on volumes that contain data. Because shard block size applies only to writes that occur after the value is set, attempting to change the value on a volume that contains data results in a mixed shard block size, which results in poor performance.
This section shows you how to safely modify the shard block size on an existing volume after upgrading to Red Hat Hyperconverged Infrastructure for Virtualization 1.1 or higher, in order to take advantage of the performance benefits of a larger shard size.
4.1.1. Changing shard size on replicated volumes Copy linkLink copied to clipboard!
Create an inventory file
Create an inventory file called
normal_replicated_inventory.yml
based on the following example.Replace
host1
,host2
, andhost3
with the FQDNs of your hosts, and edit device details to match your environment.Example
normal_replicated_inventory.yml
inventory fileCopy to Clipboard Copied! Toggle word wrap Toggle overflow Create the
normal_replicated.yml
playbookCreate a
normal_replicated.yml
playbook file using the following example:Example
normal_replicated.yml
playbookCopy to Clipboard Copied! Toggle word wrap Toggle overflow Run the playbook
ansible-playbook -i normal_replicated_inventory.yml normal_replicated.yml
ansible-playbook -i normal_replicated_inventory.yml normal_replicated.yml
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
4.1.2. Changing shard size on arbitrated volumes Copy linkLink copied to clipboard!
Create an inventory file
Create an inventory file called
arbitrated_replicated_inventory.yml
based on the following example.Replace
host1
,host2
, andhost3
with the FQDNs of your hosts, and edit device details to match your environment.Example
arbitrated_replicated_inventory.yml
inventory fileCopy to Clipboard Copied! Toggle word wrap Toggle overflow Create the
arbitrated_replicated.yml
playbookCreate a
arbitrated_replicated.yml
playbook file using the following example:Example
arbitrated_replicated.yml
playbookCopy to Clipboard Copied! Toggle word wrap Toggle overflow Run the playbook
ansible-playbook -i arbitrated_replicated_inventory.yml arbitrated_replicated.yml
ansible-playbook -i arbitrated_replicated_inventory.yml arbitrated_replicated.yml
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
4.2. Configuring a logical volume cache (lvmcache) for an existing volume Copy linkLink copied to clipboard!
If your main storage devices are not Solid State Disks (SSDs), Red Hat recommends configuring a logical volume cache (lvmcache) to achieve the required performance for Red Hat Hyperconverged Infrastructure for Virtualization deployments.
Create inventory file
Create an inventory file called
cache_inventory.yml
based on the example below.Replace
<host1>
,<host2>
, and<host3>
with the FQDNs of the hosts on which to configure the cache.Replace the following values throughout the file.
- <slow_device>,<fast_device>
-
Specify the device to which the cache should attach, followed by the cache device, as a comma-delimited list, for example,
cachedisk: '/dev/sdb,/dev/sde'
. - <fast_device_name>
-
Specify the name of the cache logical volume to create, for example,
cachelv_thinpool_gluster_vg_sde
- <fast_device_thinpool>
-
Specify the name of the cache thin pool to create, for example,
gluster_thinpool_gluster_vg_sde
.
Example cache_inventory.yml file
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Create a playbook file
Create an ansible playbook file named
lvm_cache.yml
.Example lvm_cache.yml file
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Run the playbook with the
cachesetup
tagRun the following command to apply the configuration specified in
lvm_cache.yml
to the hosts and devices specified incache_inventory.yml
.ansible-playbook -i cache_inventory.yml lvm_cache.yml --tags=cachesetup
ansible-playbook -i cache_inventory.yml lvm_cache.yml --tags=cachesetup
Copy to Clipboard Copied! Toggle word wrap Toggle overflow