This is plugin for Rally project.
With this tool you'll be able to generate load for Heketi or CNS, using various scenarios which create, expand and delete Gluster 'file' and 'block' volumes.
Install following required system packages if not installed yet:
$ yum install python-pip git gcc python-devel
Install “tox” if not installed yet:
$ pip install git+git://github.com/tox-dev/[email protected]#egg=tox
Run following command once to create DB instance for Rally project:
$ tox -e heketi -- rally db create
Then, create deployment for our Heketi plugin:
$ tox -e heketi -- rally deployment create --name heketi
Now, take some sample from 'samples/' dir, update it according to your needs and run it using following command:
$ tox -e heketi -- rally task start scenario-file-name.yaml
For running OCP scenarios you need to have kube config file on runner machine and specify it in scenario context. Default path is '~/.kube/config'. Usually, such config file available on master nodes where you run 'oc' commands. Path is the same.
For more details read Rally project docs.
Bunch of Ansible playbooks is available for doing following actions:
- Restart VMWare VMs
- Restart 'glusterd' services
- Disable and enable Heketi node
- Disable and enable Heketi device
Examples of commands to run these playbooks:
Restart of VMWare VMs:
$ tox -e ansible -- ansible-playbook \ -e vcenter_host='vcenter-hostname' \ -e vcenter_username='someUserName' \ -e vcenter_password='someCoolPassword' \ -e vcenter_vm_names="nodename1,nodename2" \ -e vm_downtime_in_seconds=13 \ ansible-playbooks/vmware-vms-restart.yaml
Restart 'glusterd' services:
$ tox -e ansible -- ansible-playbook \ -i "username@hostname,hostname2" \ -e downtime_in_seconds=3 \ ansible-playbooks/glusterd-restart.yaml
Disable Heketi node:
$ tox -e ansible -- ansible-playbook \ -i username@hostname, \ -e heketi_server=http://hostname:8080 \ -e heketi_user=admin \ -e heketi_secret=admin \ -e heketi_node_id=FooNodeID \ ansible-playbooks/heketi-node-disable.yaml
Enable Heketi node:
$ tox -e ansible -- ansible-playbook \ -i username@hostname, \ -e heketi_server=http://hostname:8080 \ -e heketi_user=admin \ -e heketi_secret=admin \ -e heketi_node_id=FooNodeID \ ansible-playbooks/heketi-node-enable.yaml
Disable Heketi device:
$ tox -e ansible -- ansible-playbook \ -i "username@hostname," \ -e heketi_server=http://hostname:8080 \ -e heketi_user=admin \ -e heketi_secret=admin \ -e heketi_device_id=FooDeviceID \ ansible-playbooks/heketi-device-disable.yaml
Enable Heketi device:
$ tox -e ansible -- ansible-playbook \ -i "username@hostname," \ -e heketi_server=http://hostname:8080 \ -e heketi_user=admin \ -e heketi_secret=admin \ -e heketi_device_id=FooDeviceID \ ansible-playbooks/heketi-device-enable.yaml